Java: test Maven Enforcer project property expansion - #22347
Merged
andersfugmann merged 2 commits intoAug 14, 2026
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 77fc65d2-e1bb-46b1-a73d-aed6101a7596
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: e435859b-f4ed-442f-b649-5e1002031780
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Maven Enforcer integration coverage for project-property expansion and Maven 3.9.16 selection.
Changes:
- Adds a
${maven.version}fixture. - Verifies Maven 3.9.16 selection.
- Adds fixture sources, resources, settings, and archive expectations.
Show a summary per file
| File | Description |
|---|---|
maven-enforcer-single-version/test.py |
Asserts selected Maven version. |
maven-enforcer-property-version/test.py |
Configures the new integration test. |
maven-enforcer-property-version/pom.xml |
Defines the property-based Maven requirement. |
maven-enforcer-property-version/settings.xml |
Configures the Maven mirror. |
maven-enforcer-property-version/source_archive.expected |
Records expected archived sources. |
maven-enforcer-property-version/src/main/java/com/example/App.java |
Checks the selected Maven installation. |
maven-enforcer-property-version/src/test/java/com/example/AppTest.java |
Supplies a sample unit test. |
maven-enforcer-property-version/src/main/resources/my-app.properties |
Supplies a sample properties resource. |
maven-enforcer-property-version/src/main/resources/page.xml |
Supplies a sample page resource. |
maven-enforcer-property-version/src/main/resources/struts.xml |
Supplies a sample Struts resource. |
Review details
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 10/10 changed files
- Comments generated: 1
- Review effort level: Balanced
jketema
reviewed
Aug 14, 2026
jketema
left a comment
Contributor
There was a problem hiding this comment.
Is this code copied and modified from a test we already had?
Contributor
Author
No. Is a copy, except the maven version is replaced with |
Contributor
|
I think you mean "Yes" 😂 |
Contributor
Author
I think I do. Yes - its a slightly modified copy 😄 |
andersfugmann
deleted the
andersfugmann/fix-maven-enforcer-property-version
branch
August 14, 2026 13:33
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.
Summary
Adds Java integration test coverage for Maven projects where the Maven Enforcer Plugin's
requireMavenVersionrule references a project property, for example${maven.version}.The tests also verify that the Java Autobuilder selects Maven 3.9.16 when it satisfies the configured version requirement.