gnodet opened a new pull request, #12852:
URL: https://github.com/apache/maven/pull/12852

   ## Summary
   
   Backport of the self-contained IT distribution extraction from master (#2476 
and #12828), adapted for the `maven-4.0.x` branch structure.
   
   **Problem:** The `run-its` profile on `4.0.x` uses 
`<mavenHome>${maven.home}</mavenHome>`, which resolves to whichever Maven 
*runs* the build — not the Maven being tested. On CI this was masked because 
the workflow downloads/extracts the built distribution and puts it on `$PATH`, 
so `${maven.home}` happens to point at the right thing. Locally, `mvn test 
-Prun-its` silently tests the wrong Maven.
   
   **Fix (pom.xml):**
   - Override `mavenHome` to `${project.build.directory}/apache-maven` in the 
`run-its` profile
   - Download the built distribution via `maven-dependency-plugin:copy`
   - Extract it via `maven-antrun-plugin`
   - This follows the same pattern already used by the `maven-from-repo` and 
`maven-distro` profiles
   
   **Fix (workflow):**
   - Remove the now-redundant download/extract/PATH steps from the 
`integration-tests` CI job
   - Use the Maven wrapper instead, since the pom.xml now handles distribution 
extraction self-contained
   
   ## Test plan
   
   - [ ] CI passes: the `integration-tests` matrix (3 OS × 3 JDK) should all 
pass
   - [ ] `full-build` job is unchanged and still passes (it still needs the 
artifact for self-hosting verification)
   - [ ] Locally, `mvn install -Prun-its` tests the built Maven distribution, 
not the building Maven
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to