-
-
Notifications
You must be signed in to change notification settings - Fork 77
Set jenkins.javaAgent
in TestRuntimeMojo
#1138
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
Conversation
<!-- Filled in by "maven-hpi-plugin" with "-javaagent:/path/to/mockito-core-<version>.jar" --> | ||
<jenkins.javaAgent /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will make the failure mode softer in the future by simply skipping a Java agent in the case that, for whatever reason, maven-hpi-plugin
doesn't fill in this value.
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-dependency-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<goals> | ||
<goal>properties</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is handled via TestRuntimeMojo
, which contains:
@Mojo(name = "test-runtime", requiresDependencyResolution = ResolutionScope.TEST)
<execution> | ||
<id>configureJavaAgent</id> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
<phase>initialize</phase> | ||
<configuration> | ||
<target> | ||
<condition else="" property="jenkins.javaAgent" value="-javaagent:${org.mockito:mockito-core:jar}"> | ||
<isset property="org.mockito:mockito-core:jar" /> | ||
</condition> | ||
</target> | ||
<exportAntProperties>true</exportAntProperties> | ||
</configuration> | ||
</execution> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reimplemented with Java code in jenkinsci/maven-hpi-plugin#741.
The plugin bill of materials fails to run tests with parent pom versions 5.13 through 5.15. Details are available in jenkinsci/bom#5000 (comment) and in the related pull requests: * jenkinsci/maven-hpi-plugin#741 * jenkinsci/plugin-pom#1138
The plugin bill of materials fails to run tests with parent pom versions 5.13 through 5.15. Details are available in jenkinsci/bom#5000 (comment) and in the related pull requests: * jenkinsci/maven-hpi-plugin#741 * jenkinsci/plugin-pom#1138
The plugin bill of materials fails to run tests with parent pom versions 5.13 through 5.15. Details are available in jenkinsci/bom#5000 (comment) and in the related pull requests: * jenkinsci/maven-hpi-plugin#741 * jenkinsci/plugin-pom#1138 Needs to be labeled `developer` so that a new release is delivered
Downstream of jenkinsci/maven-hpi-plugin#741. Fixes jenkinsci/bom#5000 (comment) by reimplementing #1130 in
maven-hpi-plugin
, thus preserving the calling convention expected by PCT.Testing done
See jenkinsci/maven-hpi-plugin#741.
Submitter checklist