Repository navigation
Decouple enforceBytecodeVersion ITs from the log4j-api fixture version - #1018
Merged
Merged
Conversation
The IT POMs and their verify scripts both pinned the exact log4j-api version, so every fixture upgrade required touching the two files in sync, and a POM-only bump failed the IT verification. Move the version into a <log4j.version> property and make the script assertions match the artifact regardless of its version. Bumping the fixture is now a one-line POM change, decreasing the maintenance cost, while the tests keep asserting the actual rule behaviour: analysis of multi-release JARs, module-info ignoring below Java 9 and the strict mode ban of classes above the maximum JDK. Both projects are refreshed to log4j-api 2.25.5.
slachiewicz
force-pushed
the
decouple-bytecode-version-its-from-log4j
branch
from
August 27, 2026 22:37
0d6f901 to
df4370a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
enforce-bytecode-version-multireleaseandenforce-bytecode-version-multirelease-strictIT projects pinned the log4j-api version twice: once in the POM and again inside theverify.groovyassertions. Every fixture upgrade therefore required touching both files in sync, and a POM-only change failed the IT verification.This PR moves the version into a
<log4j.version>property and makes the assertions version-agnostic (anchored regexes on thelog4j-apiartifact), which decreases the maintenance cost of the ITs:module-infoignoring whenmaxJdkVersion < 9, and the strict-mode ban of classes above the maximum JDKTesting:
ran both IT projects locally against
maven-enforcer-plugin3.6.4-SNAPSHOT:multireleasepasses,strictfails as required by itsinvoker.buildResult = failure, and the executed verify scripts pass in both casesverified the refactored scripts pass with the property set to both
2.17.2and2.25.5(property-only change) and still fail when the expected log lines are absentYour pull request should address just one issue, without pulling in other changes.
Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
Each commit in the pull request should have a meaningful subject line and body.
You have run the integration tests successfully (
mvn -Prun-its verify) for the affected projects.I hereby declare this contribution to be licenced under the Apache License Version 2.0, January 2004