New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade Gradle Wrapper and build against Java 18 #651
Conversation
|
JUnit 5.9.0-RC1 is causing trouble:
Will exclude it from this PR, openend #652 for that purpose. |
This reverts commit 12edd78.
We got failing tests with Java 18, seems the EnvironmentExtension needs some love |
I believe it is because of this: But why are tests passing on 17? Shouldn't the https://github.com/junit-pioneer/junit-pioneer/runs/6745721032?check_suite_focus=true#step:4:66 |
Now we get an error in the default locale extension with Java 19:
Apparently, the However, the impl notes from the deprecated
When we switch to
|
|
||
@EnabledForJreRange(max = JRE.JAVA_16, disabledReason = "See: https://github.com/junit-pioneer/junit-pioneer/issues/509") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like seeing this annotation in the wild life :D
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
me too - specially as it is my baby :D
To move on with this PR, how about excluding the update of the experimental Java version (i.e. Java 19)? I would create separate issue(s) for:
|
I support your suggestion |
src/test/java/org/junitpioneer/jupiter/AbstractEntryBasedExtensionTests.java
Outdated
Show resolved
Hide resolved
Using `=` is Gradle syntax: https://stackoverflow.com/questions/65225327/how-do-i-properly-add-add-opens-to-jvmargs-in-javaexec-task#comment115311887_65225327 In contrast, the `--add-opens` options expects a space: https://docs.oracle.com/en/java/javase/18/migrate/migrating-jdk-8-later-jdk-releases.html#GUID-12F945EB-71D6-46AF-8C3D-D354FD0B1781
(Almost) all builds are green! (That episode deserves a better rating!) Jokes aside:
|
Let's activate auto downloading toolchains for Gradle - this should fix the issue |
Gradle will use java 17 to build all kind of experimental builds. As this is the toolchain build default and configured within the gradle file
@aepfli thx for the fix! One more thing: junit-pioneer/.github/workflows/build.yml Line 155 in e68e91d
junit-pioneer/.github/workflows/build.yml Line 170 in e68e91d
I find these comments a bit confusing, both mention "execution" but use different Java version. Maybe:
WDYT? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR fixes the failing build (shakes fist at @sormuras), so we should move forward with it. Here's a review, I will take a look at the linked issues soon, to see what else needs to be addressed.
src/test/java/org/junitpioneer/internal/PioneerAnnotationUtilsTests.java
Outdated
Show resolved
Hide resolved
0eb6fda
to
5973312
Compare
Note that I also included the Java 19 upgrade (#659) into this PR by simply ignoring the deprecation warnings. Updated commit message:
|
…t-pioneer#613, junit-pioneer#659 / junit-pioneer#651) (Yes, this change does too much, but it all hangs together.) Updates the Gradle wrapper version from 7.4 to 7.5 because that comes with support for Java 18, which is also added to the build pipeline. The experimental Java version is now (for another few days), Java 19. The modular build is properly configured to really test from the module path. Furthermore, replaces the archived/deprecated GitHub action sormuras/download-jdk with oracle-actions/setup-java. Closes: junit-pioneer#613, junit-pioneer#659 PR: junit-pioneer#651
EDIT: Updated based on Nicolai's comment.
Draft because this is still open for discussion.Closes #613, #659.
Proposed commit message:
PR checklist
The following checklist shall help the PR's author, the reviewers and maintainers to ensure the quality of this project.
It is based on our contributors guidelines, especially the "writing code" section.
It shall help to check for completion of the listed points.
If a point does not apply to the given PR's changes, the corresponding entry can be simply marked as done.
Documentation (general)
.adoc
file in thedocs
folder, e.g.docs/report-entries.adoc
.adoc
file references demo insrc/demo/java
instead of containing code blocks as text.adoc
files)Documentation (new extension)
docs/docs-nav.yml
navigation has an entry for the new extensionpackage-info.java
contains information about the new extensionCode
Contributing
README.md
mentions the new contribution (real name optional)