Added dry run option
This commit is contained in:
parent
2412c525dd
commit
6243355364
3 changed files with 19 additions and 0 deletions
|
@ -283,6 +283,23 @@ public class PitestOperation extends AbstractProcessOperation<PitestOperation> {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether to run in dry run mode.
|
||||||
|
* <p>
|
||||||
|
* Defaults to {@code false}
|
||||||
|
*
|
||||||
|
* @param isDryRun {@code true} or {@code false}
|
||||||
|
* @return this operation instance
|
||||||
|
*/
|
||||||
|
public PitestOperation dryRun(boolean isDryRun) {
|
||||||
|
if (isDryRun) {
|
||||||
|
options_.put("--dryRun", TRUE);
|
||||||
|
} else {
|
||||||
|
options_.put("--dryRun", FALSE);
|
||||||
|
}
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* List of globs to match against class names. Matching classes will be excluded from mutation.
|
* List of globs to match against class names. Matching classes will be excluded from mutation.
|
||||||
*
|
*
|
||||||
|
|
|
@ -77,6 +77,7 @@ class PitestOperationTest {
|
||||||
.classPathFile(FOO)
|
.classPathFile(FOO)
|
||||||
.coverageThreshold(0)
|
.coverageThreshold(0)
|
||||||
.detectInlinedCode(false)
|
.detectInlinedCode(false)
|
||||||
|
.dryRun(false)
|
||||||
.excludedClasses("class")
|
.excludedClasses("class")
|
||||||
.excludedClasses(List.of(FOO, BAR))
|
.excludedClasses(List.of(FOO, BAR))
|
||||||
.excludedGroups("group")
|
.excludedGroups("group")
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
--classPathFile
|
--classPathFile
|
||||||
--coverageThreshold
|
--coverageThreshold
|
||||||
--detectInlinedCode
|
--detectInlinedCode
|
||||||
|
--dryRun
|
||||||
--excludedClasses
|
--excludedClasses
|
||||||
--excludedGroups
|
--excludedGroups
|
||||||
--excludedMethods
|
--excludedMethods
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue