slawekjaranowski commented on code in PR #667:
URL: https://github.com/apache/maven-surefire/pull/667#discussion_r1242765457
##########
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java:
##########
@@ -281,6 +285,21 @@ public abstract class AbstractSurefireMojo extends
AbstractMojo implements Suref
@Parameter(property = "maven.test.additionalClasspath")
private String[] additionalClasspathElements;
+ /**
+ * Additional Maven dependencies to be used in the test execution
classpath.
+ * Each element supports the parametrization like documented in <a
href="https://maven.apache.org/pom.html#dependencies">POM Reference:
Dependencies</a>.
+ * <p>
+ * Those dependencies are automatically collected (i.e. have their full
dependency tree calculated) and then all underlying artifacts are resolved from
the repository (including their transitive dependencies).
+ * Afterwards the resolved artifacts are filtered to only contain {@code
compile} and {@code runtime} scoped ones and appended to the test execution
classpath
+ * (after the ones from {@link #additionalClasspathElements}).
+ * <p>
+ * The dependency management from the project is not taken into account.
+ *
+ * @since 3.2
+ */
+ @Parameter(property = "maven.test.additionalClasspathDependencies")
+ private Dependency[] additionalClasspathDependencies;
Review Comment:
`List<Dependency>`?
with empty list as default - we will not need check for null value
##########
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java:
##########
@@ -3474,6 +3552,14 @@ public void setAdditionalClasspathElements(String[]
additionalClasspathElements)
this.additionalClasspathElements = additionalClasspathElements;
}
+ public Dependency[] getAdditionalClasspathDependencies() {
+ return additionalClasspathDependencies;
+ }
+
+ public void setAdditionalClasspathDependencies(Dependency[]
additionalClasspathDependencies) {
+ this.additionalClasspathDependencies = additionalClasspathDependencies;
+ }
Review Comment:
we don't use this values outside class - so getter and setter are not needed.
--
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]