Closed abelsromero closed 1 year ago
Windows failures...
It seems Windows has some issues cleaning test directories, it's related to https://github.com/junit-team/junit5/issues/2811. Right now I am considering not deleting temp directories :thinking: The OS will eventually do that.
Most of the changes are boilerplate, but there are still a lot. No hurry.
Let's get modern! 🚀
P.S.: Sorry for that stupid question, where can I find the logs that seem to be uploaded from the Github action? Sorry if I sound stupid, but I've never used that feature yet :)
P.S.: Sorry for that stupid question
Not at all, in fact imo the location should be improved. Just open an execution detail sand scroll to botom https://github.com/asciidoctor/asciidoctorj/actions/runs/4788558210 to the "Artifacts" section.
We could have a custom job that aggregates them all to have a single zip with some bash, but for now, I am going for a quick one. Downside is yaml duplication. The env mapping in the config is necessary because you cannot use matrix variables directly :shrug:
Kind of change
Description
What is the goal of this pull request?
Make JUnit5 de default testing framework. Not possible in Wilddly integration test which requires heavy Arquillian changes and the use of an Arquiliar RC version (https://github.com/arquillian/arquillian-core/issues/137#issuecomment-726596414).
How does it achieve that?
Sets JUnit5 as the default test engine.
Rewrites polluted tests "category" into a JUnit 5 "tag". The Tag is applied via new annotation
@Polluted
which I personally thing it's nicer that plain using the tag.Only minimal changes are done, test that can still work in "junit 4 mode" using
junit-vintage-engine
still use. But at the end only core project requires it, some minimal rewrites allowed to remove it from documentation, cli and distribution modules.Removed use of ClasspathResource Test Rule which is not compatible, currently just replaced with use of ClasspathHelper + initializations in each test, I may refactor better when I get some extra time. I want to reduce boilerplate with a junit5 extension in another PR (see checklist).
Restrict codenarc configuration to only required modules
Other changes
codenarc
configuration did not override the Groovy version in use, I applied it viaconstraint
. It can be validated by listing dependencies for codenarc configuration (./gradlew :module:dependencies
).Are there any alternative ways to implement this?
Maybe go for "big bang" but I'd rather not do that. We can get something working, merge, and then migrate over time, next way we are removing the use of deprecated methods from tests when we need to review them.
Are there any implications of this pull request? Anything a user must know?
No
Issue
Related to #1186, we'll see how far we can get to completion in this one PR. :crossed_fingers:
Release notes
Please add a corresponding entry to the file CHANGELOG.adoc
Added a note to the change just in case someone follows the repo and wants to see what's going on, I will update with the next PR when all is done and we can consider the migration completed.