Skip to content
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

Support arbitrary Java versions with JRE conditions #3930

Closed
13 tasks done
sbrannen opened this issue Aug 20, 2024 · 1 comment
Closed
13 tasks done

Support arbitrary Java versions with JRE conditions #3930

sbrannen opened this issue Aug 20, 2024 · 1 comment

Comments

@sbrannen
Copy link
Member

sbrannen commented Aug 20, 2024

Overview

Inspired by #3918 and related discussions, we should consider introducing a mechanism for users to supply arbitrary Java feature versions that are not yet covered by the JRE enum constants.

Note that a "feature" version refers to the leading number in a Java version -- for example, the 21 in 21.0.4. In Java 9, this was referred to as the major number (JEP 223), but the terminology changed to feature in Java 10 (JEP 322).

Deliverables

  • Investigate options.
  • Revise JRE (via JRE.java.jte) to support feature versions.
  • Introduce versions attribute in @EnabledOnJre and revise EnabledOnJreCondition accordingly.
  • Introduce versions attribute in @DisabledOnJre and revise DisabledOnJreCondition accordingly.
  • Introduce minVersion and maxVersion attributes in @EnabledForJreRange and revise EnabledForJreRangeCondition accordingly.
  • Introduce minVersion and maxVersion attributes in @DisabledForJreRange and revise DisbledForJreRangeCondition accordingly.
  • Revise EnabledOnJreIntegrationTests, DisabledOnJreIntegrationTests, EnabledOnJreConditionTests, DisabledOnJreConditionTests, etc.
  • There are no TODOs left in the code.
  • Method preconditions are checked and documented in the method's Javadoc.
  • Coding conventions (e.g. for logging) have been followed.
  • Change is covered by automated tests including corner cases, errors, and exception handling.
  • Public API has Javadoc and @API annotations.
  • Change is documented in the User Guide and Release Notes.
@sbrannen sbrannen added this to the 5.12 M1 milestone Aug 20, 2024
@sbrannen sbrannen self-assigned this Aug 20, 2024
sbrannen added a commit to sbrannen/junit5 that referenced this issue Aug 20, 2024
This commit serves as a proof of concept for supporting arbitrary Java
feature numbers in @⁠EnabledOnJre, @⁠EnabledForJreRange, and the JRE enum.

See junit-team#3930
@sbrannen
Copy link
Member Author

sbrannen commented Aug 20, 2024

@sbrannen sbrannen changed the title Support arbitrary Java feature numbers with JRE conditions Support arbitrary Java feature versions with JRE conditions Aug 20, 2024
@marcphilipp marcphilipp linked a pull request Jan 27, 2025 that will close this issue
6 tasks
@marcphilipp marcphilipp modified the milestones: 5.12.0-M1, 5.12.0-RC1 Jan 31, 2025
sbrannen added a commit to sbrannen/junit5 that referenced this issue Jan 31, 2025
This commit introduces support for arbitrary Java feature numbers in
the JRE enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange,
and @⁠DisabledForJreRange.

See junit-team#3930
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 1, 2025
This commit introduces support for arbitrary Java feature numbers in
the JRE enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange,
and @⁠DisabledForJreRange.

See junit-team#3930
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 1, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
@sbrannen sbrannen changed the title Support arbitrary Java feature versions with JRE conditions Support arbitrary Java versions with JRE conditions Feb 1, 2025
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 1, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 1, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 2, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 2, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
Closes: junit-team#3931
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 2, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
Closes: junit-team#3931
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 3, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
Closes: junit-team#3931
sbrannen added a commit to sbrannen/junit5 that referenced this issue Feb 3, 2025
This commit introduces support for arbitrary Java versions in the JRE
enum, @⁠EnabledOnJre, @⁠DisabledOnJre, @⁠EnabledForJreRange, and
@⁠DisabledForJreRange.

Closes: junit-team#3930
Closes: junit-team#3931
sbrannen added a commit that referenced this issue Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants