Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions java/maven/src/org/netbeans/modules/maven/TestChecker.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,19 @@
public class TestChecker implements PrerequisitesChecker {

/**
* Skip test execution.
* Skip (unit) test execution.
* Do not use maven.test.skip as that skips also compilation; see #189466 for background.
* http://maven.apache.org/plugins/maven-surefire-plugin/examples/skipping-test.html
* https://maven.apache.org/surefire/maven-surefire-plugin/examples/skipping-tests.html
*/
public static final String PROP_SKIP_TEST = "skipTests"; // NOI18N
/**
* Skip integration test execution.
* Since surefire 3.6.0, skipTests only skips unit tests;
* integration tests must be skipped with the "skipITs" property
* https://maven.apache.org/surefire/maven-failsafe-plugin/integration-test-mojo.html#skipITs
* https://maven.apache.org/surefire/#3-6-0
*/
public static final String PROP_SKIP_ITS = "skipITs"; // NOI18N

@Override public boolean checkRunConfig(RunConfig config) {
String action = config.getActionName();
Expand Down Expand Up @@ -75,6 +83,9 @@ public class TestChecker implements PrerequisitesChecker {
if (config.getProperties().get(PROP_SKIP_TEST) == null) {
config.setProperty(PROP_SKIP_TEST, "true"); //NOI18N
}
if (config.getProperties().get(PROP_SKIP_ITS) == null) {
config.setProperty(PROP_SKIP_ITS, "true"); //NOI18N
}
}
}
if (ActionProvider.COMMAND_TEST_SINGLE.equals(action) ||
Expand Down
Loading