Repository navigation
Add maven-executor-verifier, a Verifier on top of the executors - #66
Closed
slachiewicz wants to merge 2 commits into
Closed
slachiewicz wants to merge 2 commits into
slachiewicz wants to merge 2 commits into
Conversation
Seven IT suites that moved off maven-verifier each wrote about 2,100 lines of the same Verifier helpers. This module holds them once: running Maven with -e --batch-mode, autoclean and the log file, the log, file and artifact checks, filtering, and ResourceExtractor. It is seeded from apache/maven-integration-testing#446 without the members kept there only for source compatibility with maven-verifier, depends on maven-executor only, and computes paths through DefaultExecutorTool. addCliOption() splits an option such as "-pl x -am" into separate arguments. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 5, 2026
The rc-6 deadlock behind E1 is fixed in 4.0.0-rc-7, which the build uses; all three scenarios pass embedded. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Stacked on #65 (A7, plugin-free paths): this PR targets its branch, so the diff shows only the new module; it retargets to
mainonce #65 is merged.Seven IT suites that moved off maven-verifier (sources table in #49) each wrote about 2,100 lines of the same Verifier helpers, and review of apache/maven-integration-testing#446 asked for them in one place instead. This is T1 in #49: a
maven-executor-verifiermodule, Java 8, depending onmaven-executoronly.Verifier, seeded from apache/maven-integration-testing#446:execute()runs Maven in the base directory with-e --batch-mode,-Dmaven.repo.local,maven-clean-plugin:cleanfirst unlesssetAutoclean(false), the system properties as-Dand then the arguments; stdout and stderr go to the log file (log.txt,setLogFileName). A non-zero exit throwsVerificationExceptionwith the command line and the log.maven.home, in the mode ofverifier.forkMode(forked when unset), with one sharedExecutorHelperper installation for the life of the JVM; or anyExecutorHelpergiven to the constructor.verifyErrorFreeLog(an[ERROR]scan that ignores old Doxia's Velocity noise),verifyTextInLog, and the newverifyTextNotInLog, all ignoring ANSI colours.verifyFilePresent/NotPresentwith*patterns anda.jar!/entry;loadLines,loadProperties,loadFilewith${artifact:…}markers,filterFile,newDefaultFilterMap.getLocalRepository,getArtifactPath,getArtifactMetadataPath,verifyArtifact*,deleteArtifact(s). Paths come from anExecutorTool,DefaultExecutorToolfrom Compute local repository and artifact paths without a plugin #65 by default, so no plugin is resolved. Packaging types that are stored under another extension (maven-plugin,test-jar,ejb-client, …) are mapped; a suite adds its own by overridingextensionAndClassifier(the core ITs'coreit-artifact, for example).addCliArgumentadds one argument as is; the newaddCliOption("-pl x -am")splits on whitespace like maven-verifier 1.x. Replace maven-verifier with an in-repo Verifier on maven-executor maven-build-cache-extension#536 failed on exactly that.Left out on purpose, per review of #446: the members kept there only for source compatibility with maven-verifier:
Verifier(String, boolean),displayStreamBuffers(),setCliOptions(List),filterFile(…, Properties),getLocalRepoLayout()and theUSER_HOMEconstants. Consumers migrate those call sites. maven-shared-utils is replaced by the JDK.ResourceExtractor: same API, without maven-shared-utils. It fixes a bug in the seed: theZipFilewas closed inside the loop after the first file, so extracting a test project with more than one file from a jar failed. A relative resource path now resolves against the class's package, and a jar entry can't escape the target directory.Behaviour differences from the seed:
verifyArtifactNotPresentchecks the artifact file only (the seed also failed when metadata next to it existed), and${artifact:…}markers list the metadata of the version and artifact directories for lines with and without a command alike.Tests (all pass;
mvn verifypasses for the reactor):VerifierTest: 9 tests without running Maven: argument splitting, local repository lookup, artifact and metadata paths, a suite type through the override, artifact checks and deletion, log checks with ANSI and Velocity lines, file and jar-entry checks, filtering,${artifact:}markers.ResourceExtractorTest: a directory with several files extracted from a jar (fails on the seed), and a class-path directory used in place or copied.VerifierExecuteTest: forked and embedded Maven 3 and Maven 4 (4.0.0-rc-7):installthen artifact checks;addCliOption("-pl b -am validate")builds a and b but not c; a failing build throws and leaves its log.Not in this PR: T2 (the JUnit 5 extension) and A3 (
Builder.logFile). The module version follows the reactor, and #49 places T1 in 2.x.Part of #49
🤖 Generated with Claude Code