Class PitestOperation
- Since:
- 1.0
- Author:
- Erik C. Thauvin
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumSupported output formats.static enumVerbosity of output. -
Field Summary
Fields inherited from class rife.bld.operations.AbstractProcessOperation
classpath_, DEFAULT_JAVA_TOOL, environment_, errorProcessor_, errorProcessorThread_, javaOptions_, javaTool_, mainClass_, module_, modulePath_, outputProcessor_, outputProcessorThread_, process_, successful_, workDirectory_ -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionLine arguments for child JVMs.avoidCallsTo(String... values) List of packages and classes which are to be considered outside the scope of mutation.final PitestOperationavoidCallsTo(Collection<String> values) List of packages and classes which are to be considered outside the scope of mutation.List of additional classpath entries to use when looking for tests and mutable code.List of additional classpath entries to use when looking for tests and mutable code.List of additional classpath entries to use when looking for tests and mutable code.final PitestOperationclassPath(Collection<String> values) List of additional classpath entries to use when looking for tests and mutable code.classPathFile(File file) File with a list of additional classpath elements (one per line).classPathFile(String file) File with a list of additional classpath elements (one per line).classPathFile(Path path) File with a list of additional classpath elements (one per line).final PitestOperationclassPathFiles(Collection<File> values) Additional classpath entries to use when looking for tests and mutable code.final PitestOperationclassPathPaths(Collection<Path> values) Additional classpath entries to use when looking for tests and mutable code.Directory to examine for configuration.Directory to examine for configuration.Directory to examine for configuration.coverageThreshold(int threshold) Line coverage threshold below which the build will fail.detectInlinedCode(boolean value) Flag to indicate if PIT should attempt to detect the inlined code generated by the java compiler in order to implementfinallyblocks.dryRun(boolean value) Whether to run in dry run mode.excludedClasses(String... values) List of globs to match against class names.final PitestOperationexcludedClasses(Collection<String> values) List of globs to match against class names.excludedGroups(String... values) List of TestNG groups/JUnit categories to exclude from mutation analysisfinal PitestOperationexcludedGroups(Collection<String> values) List of TestNG groups/JUnit categories to exclude from mutation analysisexcludedMethods(String... values) List of globs to match against method names.final PitestOperationexcludedMethods(Collection<String> values) List of globs to match against method names.excludedRunners(String... runners) JUnit4 runners to exclude.excludedRunners(Collection<String> runners) JUnit4 runners to exclude.excludedTestClasses(String... values) List of globs to match against test class names.final PitestOperationexcludedTestClasses(Collection<String> values) List of globs to match against test class names.Part of theAbstractProcessOperation.execute()operation, constructs the command list to use for building the process.exportLineCoverage(boolean value) Whether or not to dump per test line coverage data to disk.failWhenNoMutations(boolean value) Whether to create a full mutation matrixList of features to enable/disablefinal PitestOperationfeatures(Collection<String> values) List of features to enable/disablefromProject(BaseProject project) Configures the operation from aBaseProject.fullMutationMatrix(boolean value) Whether to create a full mutation matrixhistoryInputLocation(File path) Path to a file containing history information for incremental analysis.historyInputLocation(String path) Path to a file containing history information for incremental analysis.historyInputLocation(Path path) Path to a file containing history information for incremental analysis.historyOutputLocation(File path) Path to write history information for incremental analysis.historyOutputLocation(String path) Path to write history information for incremental analysis.historyOutputLocation(Path path) Path to write history information for incremental analysis.includedGroups(String... values) List of TestNG groups/JUnit categories to include in mutation analysis.final PitestOperationincludedGroups(Collection<String> values) List of TestNG groups/JUnit categories to include in mutation analysis.includedTestMethods(String... testMethod) Test methods that should be included for challenging the mutants.includedTestMethods(Collection<String> testMethod) Test methods that should be included for challenging the mutants.includeLaunchClasspath(boolean value) Indicates if the PIT should try to mutate classes on the classpath with which it was launched.inputEncoding(String encoding) Input encoding.Argument string to use when PIT launches child processes.final PitestOperationjvmArgs(Collection<String> args) Argument string to use when PIT launches child processes.The path to the java executable to be used to launch test with.The path to the java executable to be used to launch test with.The path to the java executable to be used to launch test with.maxMutationsPerClass(int max) Maximum number of surviving mutants to allow without throwing an error.maxSurviving(int max) Maximum number of surviving mutants to allow without throwing an error.mutableCodePaths(File... values) List of classpaths which should be considered to contain mutable code.mutableCodePaths(String... values) List of classpaths which should be considered to contain mutable code.mutableCodePaths(Path... values) List of classpaths which should be considered to contain mutable code.final PitestOperationmutableCodePaths(Collection<String> values) List of classpaths which should be considered to contain mutable code.final PitestOperationmutableCodePathsFiles(Collection<File> values) List of classpaths which should be considered to contain mutable code.final PitestOperationmutableCodePathsPaths(Collection<Path> values) List of classpaths which should be considered to contain mutable code.mutationEngine(String engine) Mutation engine to use.mutationThreshold(int threshold) Mutation score threshold below which the build will fail.mutationUnitSize(int size) Maximum number of mutations to include.List of mutation operators.final PitestOperationmutators(Collection<String> values) List of mutation operators.options()Returns the PIT options.outputEncoding(String encoding) Output encoding.outputFormats(PitestOperation.OutputFormat... formats) A list of formats in which to write mutation results as the mutations are analysed.pluginConfiguration(Map<String, String> configuration) Custom plugin properties.projectBase(File file) Project base.projectBase(String file) Project base.projectBase(Path file) Project base.Output directory for the reports.Output directory for the reports.Output directory for the reports.skipFailingTests(boolean value) Whether to ignore failing tests when computing coverage.sourceDirs(File... dirs) The folder(s) containing the source code.sourceDirs(String... dirs) The folder(s) containing the source code.sourceDirs(Path... dirs) The folder(s) containing the source code.final PitestOperationsourceDirs(Collection<String> dirs) The folder(s) containing the source code.final PitestOperationsourceDirsFiles(Collection<File> dirs) The folder(s) containing the source code.final PitestOperationsourceDirsPaths(Collection<Path> dirs) The folder(s) containing the source code.targetClasses(String... values) The classes to be mutated.final PitestOperationtargetClasses(Collection<String> values) The classes to be mutated.targetTests(String... values) A list of globs can be supplied to this parameter to limit the tests available to be run.final PitestOperationtargetTests(Collection<String> values) A list of globs can be supplied to this parameter to limit the tests available to be run.testStrengthThreshold(int threshold) Test strength score below which to throw an error.threads(int threads) The number of threads to use when mutation testing.timeoutConst(int factor) Constant amount of additional time to allow a test to run for (after the application of the timeoutFactor) before considering it to be stuck in an infinite loop.timeoutFactor(double factor) A factor to apply to the normal runtime of a test when considering if it is stuck in an infinite loop.timestampedReports(boolean value) By default, PIT will create a date and time stamped folder for its output each time it is run.useClasspathJar(boolean value) Support large classpaths by creating a classpath jar.verbose(boolean value) Output verbose logging.verbosity(PitestOperation.Verbosity verbosity) The verbosity of output.Methods inherited from class rife.bld.operations.AbstractProcessOperation
classpath, classpath, classpath, classpath, classpath, environment, environment, environment, errorProcessor, errorProcessor, execute, executeStartProcess, javaOptions, javaOptions, javaTool, javaTool, mainClass, mainClass, module, module, modulePath, modulePath, modulePath, modulePath, modulePath, outputProcessor, outputProcessor, process, workDirectory, workDirectoryMethods inherited from class rife.bld.operations.AbstractOperation
executeOnce, executeOnce, silent, silent
-
Constructor Details
-
PitestOperation
public PitestOperation()
-
-
Method Details
-
executeConstructProcessCommandList
Part of theAbstractProcessOperation.execute()operation, constructs the command list to use for building the process.- Specified by:
executeConstructProcessCommandListin classAbstractProcessOperation<PitestOperation>
-
fromProject
Configures the operation from aBaseProject.The
source directorieswill the set the project's source directories during execution, if not already set.- Specified by:
fromProjectin classAbstractProcessOperation<PitestOperation>- Parameters:
project- the project to configure the operation from- Returns:
- this operation instance
-
argLine
Line arguments for child JVMs.- Parameters:
line- the line arguments- Returns:
- this operation instance
-
avoidCallsTo
List of packages and classes which are to be considered outside the scope of mutation. Any lines of code containing calls to these classes will not be mutated.If a list is not explicitly supplied then PIT will default to a list of common logging packages as follows
- java.util.logging
- org.apache.log4j
- org.slf4j
- org.apache.commons.logging
If the feature
FLOGCALLis disabled, this parameter is ignored and logging calls are also mutated.- Parameters:
values- the list of packages- Returns:
- this operation instance
- See Also:
-
avoidCallsTo
List of packages and classes which are to be considered outside the scope of mutation. Any lines of code containing calls to these classes will not be mutated.If a list is not explicitly supplied then PIT will default to a list of common logging packages as follows
- java.util.logging
- org.apache.log4j
- org.slf4j
- org.apache.commons.logging
If the feature
FLOGCALLis disabled, this parameter is ignored and logging calls are also mutated.- Parameters:
values- the list of packages- Returns:
- this operation instance
- See Also:
-
classPath
List of additional classpath entries to use when looking for tests and mutable code.These will be used in addition to the classpath with which PIT is launched.
- Parameters:
values- the list of paths- Returns:
- this operation instance
- See Also:
-
classPath
List of additional classpath entries to use when looking for tests and mutable code.These will be used in addition to the classpath with which PIT is launched.
- Parameters:
values- one or more paths- Returns:
- this operation instance
- See Also:
-
classPath
List of additional classpath entries to use when looking for tests and mutable code.These will be used in addition to the classpath with which PIT is launched.
- Parameters:
values- one or more paths- Returns:
- this operation instance
- See Also:
-
classPath
List of additional classpath entries to use when looking for tests and mutable code.These will be used in addition to the classpath with which PIT is launched.
- Parameters:
values- one or more paths- Returns:
- this operation instance
- See Also:
-
classPathFile
File with a list of additional classpath elements (one per line).- Parameters:
file- the file- Returns:
- this operation instance
- See Also:
-
classPathFile
File with a list of additional classpath elements (one per line).- Parameters:
file- the file- Returns:
- this operation instance
- See Also:
-
classPathFile
File with a list of additional classpath elements (one per line).- Parameters:
path- the file- Returns:
- this operation instance
- See Also:
-
classPathFiles
Additional classpath entries to use when looking for tests and mutable code.- Parameters:
values- the list of paths- Returns:
- this operation instance
- See Also:
-
classPathPaths
Additional classpath entries to use when looking for tests and mutable code.- Parameters:
values- the list of paths- Returns:
- this operation instance
- See Also:
-
configDir
Directory to examine for configuration.- Parameters:
dir- the directory- Returns:
- this operation instance
- See Also:
-
configDir
Directory to examine for configuration.- Parameters:
dir- the directory path- Returns:
- this operation instance
- See Also:
-
configDir
Directory to examine for configuration.- Parameters:
dir- the directory- Returns:
- this operation instance
- See Also:
-
coverageThreshold
Line coverage threshold below which the build will fail. This is an integer percent (0-100) that represents the fraction of the project covered by the tests.- Parameters:
threshold- the threshold- Returns:
- this operation instance
-
detectInlinedCode
Flag to indicate if PIT should attempt to detect the inlined code generated by the java compiler in order to implementfinallyblocks. Each copy of the inlined code would normally be mutated separately, resulting in multiple identical looking mutations. When inlined code detection is enabled PIT will attempt to spot inlined code and create only a single mutation that mutates all affected instructions simultaneously.The algorithm cannot easily distinguish between inlined copies of code, and genuine duplicate instructions on the same line within a
finallyblock.In the case of any doubt PIT will act cautiously and assume that the code is not inlined.
This will be detected as two separate inlined instructions
finally { int++; int++; }But this will look confusing so PIT will assume no in-lining is taking place.finally { int++; int++; }This sort of pattern might not be common with integer addition, but things like string concatenation are likely to produce multiple similar instructions on the same line.Defaults to
true- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
dryRun
Whether to run in dry run mode.Defaults to
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
excludedClasses
List of globs to match against class names. Matching classes will be excluded from mutation.- Parameters:
values- the excluded classes- Returns:
- this operation instance
- See Also:
-
excludedClasses
List of globs to match against class names. Matching classes will be excluded from mutation.- Parameters:
values- the excluded classes- Returns:
- this operation instance
- See Also:
-
excludedGroups
List of TestNG groups/JUnit categories to exclude from mutation analysisNote that only class level categories are supported.
- Parameters:
values- the excluded groups- Returns:
- this operation instance
- See Also:
-
excludedGroups
List of TestNG groups/JUnit categories to exclude from mutation analysisNote that only class level categories are supported.
- Parameters:
values- one or more excluded groups- Returns:
- this operation instance
- See Also:
-
excludedMethods
List of globs to match against method names. Methods matching the globs will be excluded from mutation.- Parameters:
values- the excluded methods- Returns:
- this operation instance
- See Also:
-
excludedMethods
List of globs to match against method names. Methods matching the globs will be excluded from mutation.- Parameters:
values- one or more excluded methods- Returns:
- this operation instance
- See Also:
-
excludedRunners
JUnit4 runners to exclude.- Parameters:
runners- the runners- Returns:
- this operation instance
-
excludedRunners
JUnit4 runners to exclude.- Parameters:
runners- the runners- Returns:
- this operation instance
-
excludedTestClasses
List of globs to match against test class names. Matching tests will not be run (note if a test suite includes an excluded class, then it will "leak" back in).- Parameters:
values- the excluded tests- Returns:
- this operation instance
- See Also:
-
excludedTestClasses
List of globs to match against test class names. Matching tests will not be run (note if a test suite includes an excluded class, then it will "leak" back in).- Parameters:
values- one or more excluded tests- Returns:
- this operation instance
- See Also:
-
exportLineCoverage
Whether or not to dump per test line coverage data to disk.Defaults to
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
failWhenNoMutations
Whether to create a full mutation matrix- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
features
List of features to enable/disable- Parameters:
values- one or more features- Returns:
- this operation instance
- See Also:
-
features
List of features to enable/disable- Parameters:
values- one or more features- Returns:
- this operation instance
- See Also:
-
fullMutationMatrix
Whether to create a full mutation matrix- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
historyInputLocation
Path to a file containing history information for incremental analysis.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
historyInputLocation
Path to a file containing history information for incremental analysis.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
historyInputLocation
Path to a file containing history information for incremental analysis.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
historyOutputLocation
Path to write history information for incremental analysis. May be the same ashistoryInputLocation(String).- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
historyOutputLocation
Path to write history information for incremental analysis. May be the same ashistoryInputLocation(String).- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
historyOutputLocation
Path to write history information for incremental analysis. May be the same ashistoryInputLocation(String).- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
includeLaunchClasspath
Indicates if the PIT should try to mutate classes on the classpath with which it was launched. If not supplied this flag defaults totrue. If set tofalseonly classes found on the paths specified by theclassPathDefaults to
true- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
includedGroups
List of TestNG groups/JUnit categories to include in mutation analysis. Note that only class level categories are supported.- Parameters:
values- the list of included groups- Returns:
- this operation instance
- See Also:
-
includedGroups
List of TestNG groups/JUnit categories to include in mutation analysis. Note that only class level categories are supported.- Parameters:
values- one or more included groups- Returns:
- this operation instance
-
includedTestMethods
Test methods that should be included for challenging the mutants.- Parameters:
testMethod- the test methods- Returns:
- this operation instance
-
includedTestMethods
Test methods that should be included for challenging the mutants.- Parameters:
testMethod- the test methods- Returns:
- this operation instance
-
inputEncoding
Input encoding.Default is
UTF-8.- Parameters:
encoding- the encoding- Returns:
- this operation instance
-
jvmArgs
Argument string to use when PIT launches child processes. This is most commonly used to increase the amount of memory available to the process, but may be used to pass any valid JVM argument.- Parameters:
args- the list of args- Returns:
- this operation instance
- See Also:
-
jvmArgs
Argument string to use when PIT launches child processes. This is most commonly used to increase the amount of memory available to the process, but may be used to pass any valid JVM argument.- Parameters:
args- one or more args- Returns:
- this operation instance
- See Also:
-
jvmPath
The path to the java executable to be used to launch test with. If none is supplied defaults to the one pointed to byJAVA_HOME.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
jvmPath
The path to the java executable to be used to launch test with. If none is supplied defaults to the one pointed to byJAVA_HOME.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
jvmPath
The path to the java executable to be used to launch test with. If none is supplied defaults to the one pointed to byJAVA_HOME.- Parameters:
path- the path- Returns:
- this operation instance
- See Also:
-
maxMutationsPerClass
Maximum number of surviving mutants to allow without throwing an error.- Parameters:
max- the max number- Returns:
- this operation instance
-
maxSurviving
Maximum number of surviving mutants to allow without throwing an error.- Parameters:
max- the maximum number- Returns:
- this operation instance
-
mutableCodePaths
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- the list of values- Returns:
- this operation instance
- See Also:
-
mutableCodePaths
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- one or more values- Returns:
- this operation instance
- See Also:
-
mutableCodePaths
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- one or more values- Returns:
- this operation instance
- See Also:
-
mutableCodePaths
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- one or more values- Returns:
- this operation instance
- See Also:
-
mutableCodePathsFiles
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- the list of values- Returns:
- this operation instance
- See Also:
-
mutableCodePathsPaths
List of classpaths which should be considered to contain mutable code. If your build maintains separate output directories for tests and production classes this parameter should be set to your code output directory in order to avoid mutating test helper classes etc.If no mutableCodePath is supplied PIT will default to considering anything not defined within a jar or zip file as being a candidate for mutation.
PIT will always attempt not to mutate test classes even if they are defined on a mutable path.
- Parameters:
values- the list of values- Returns:
- this operation instance
- See Also:
-
mutationEngine
Mutation engine to use.Defaults to
gregor- Parameters:
engine- the engine- Returns:
- this operation instance
-
mutationThreshold
Mutation score threshold below which the build will fail. This is an integer percent (0-100) that represents the fraction of killed mutations out of all mutations.Please bear in mind that your build may contain equivalent mutations. Careful thought must therefore be given when selecting a threshold.
- Parameters:
threshold- the threshold- Returns:
- this operation instance
-
mutationUnitSize
Maximum number of mutations to include.- Parameters:
size- the size- Returns:
- this operation instance
-
mutators
List of mutation operators.- Parameters:
values- one or more mutators- Returns:
- this operation instance
- See Also:
-
mutators
List of mutation operators.- Parameters:
values- the list of mutators- Returns:
- this operation instance
- See Also:
-
options
Returns the PIT options.- Returns:
- the mutable map of options
-
outputEncoding
Output encoding.Default is
UTF-8.- Parameters:
encoding- the encoding- Returns:
- this operation instance
-
outputFormats
A list of formats in which to write mutation results as the mutations are analysed.Supported formats are
PitestOperation.OutputFormat.HTML,PitestOperation.OutputFormat.XML,PitestOperation.OutputFormat.CSV.Defaults to
PitestOperation.OutputFormat.HTML.- Parameters:
formats- one or more output formats- Returns:
- this operation instance
-
pluginConfiguration
Custom plugin properties.- Parameters:
configuration- the configuration keys and values- Returns:
- this operation instance
-
projectBase
Project base.- Parameters:
file- the file- Returns:
- this operations instance
- See Also:
-
projectBase
Project base.- Parameters:
file- the file- Returns:
- this operations instance
- See Also:
-
projectBase
Project base.- Parameters:
file- the file- Returns:
- this operations instance
- See Also:
-
reportDir
Output directory for the reports.- Parameters:
dir- the directory- Returns:
- this operation instance
- See Also:
-
reportDir
Output directory for the reports.- Parameters:
dir- the directory- Returns:
- this operation instance
- See Also:
-
reportDir
Output directory for the reports.- Parameters:
dir- the directory- Returns:
- this operation instance
- See Also:
-
skipFailingTests
Whether to ignore failing tests when computing coverage.Default is
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
sourceDirs
The folder(s) containing the source code.- Parameters:
dirs- one or more directories- Returns:
- this operation instance
- See Also:
-
sourceDirs
The folder(s) containing the source code.- Parameters:
dirs- one or more directories- Returns:
- this operation instance
- See Also:
-
sourceDirs
The folder(s) containing the source code.- Parameters:
dirs- one or more directories- Returns:
- this operation instance
- See Also:
-
sourceDirs
The folder(s) containing the source code.- Parameters:
dirs- the list of directories- Returns:
- this operation instance
- See Also:
-
sourceDirsFiles
The folder(s) containing the source code.- Parameters:
dirs- the list of directories- Returns:
- this operation instance
- See Also:
-
sourceDirsPaths
The folder(s) containing the source code.- Parameters:
dirs- the list of directories- Returns:
- this operation instance
- See Also:
-
targetClasses
The classes to be mutated. This is expressed as a list of globs.For example:
com.mycompany.*com.mycompany.package.*, com.mycompany.packageB.Foo, com.partner.*
- Parameters:
values- the list of target classes- Returns:
- this operation instance
- See Also:
-
targetClasses
The classes to be mutated. This is expressed as a list of globs.For example:
com.mycompany.*com.mycompany.package.*, com.mycompany.packageB.Foo, com.partner.*
- Parameters:
values- one or more target classes- Returns:
- this operation instance
- See Also:
-
targetTests
A list of globs can be supplied to this parameter to limit the tests available to be run. If this parameter is not supplied then any test fixture that matched targetClasses may be used, it is however recommended that this parameter is always explicitly set.This parameter can be used to point PIT to a top level suite or suites. Custom suites such as ClassPathSuite are supported.
- Parameters:
values- the list of tests- Returns:
- this operation instance
- See Also:
-
targetTests
A list of globs can be supplied to this parameter to limit the tests available to be run. If this parameter is not supplied then any test fixture that matched targetClasses may be used, it is however recommended that this parameter is always explicitly set.This parameter can be used to point PIT to a top level suite or suites. Custom suites such as ClassPathSuite are supported.
- Parameters:
values- one or more tests- Returns:
- this operation instance
- See Also:
-
testStrengthThreshold
Test strength score below which to throw an error.Threshold must be between 0 and 100.
- Parameters:
threshold- the threshold- Returns:
- this operation instance
-
threads
The number of threads to use when mutation testing.- Parameters:
threads- the threads count- Returns:
- this operation instance
-
timeoutConst
Constant amount of additional time to allow a test to run for (after the application of the timeoutFactor) before considering it to be stuck in an infinite loop.Defaults to
4000- Parameters:
factor- the factor amount- Returns:
- this operation instance
-
timeoutFactor
A factor to apply to the normal runtime of a test when considering if it is stuck in an infinite loop.Defaults to
1.25- Parameters:
factor- the factor- Returns:
- this operation instance
-
timestampedReports
By default, PIT will create a date and time stamped folder for its output each time it is run. This can can make automation difficult, so the behaviour can be suppressed by passingfalse.Defaults to
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
useClasspathJar
Support large classpaths by creating a classpath jar.Defaults to
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
verbose
Output verbose logging.Defaults to
false- Parameters:
value-trueorfalse- Returns:
- this operation instance
-
verbosity
The verbosity of output.Defaults to
Verbosity.DEFAULT- Parameters:
verbosity- the verbosity- Returns:
- this operation instance
-