MutantResult
record in io.mutastic.api
record MutantResult( Mutant mutant, Status status, List<String> coveredBy, Optional<String> caughtBy, Optional<String> failure, Optional<String> failureOrigin, int testsRun, Optional<String> unconfirmed, Map<String, List<Long>> inputs, Optional<Suggestion> suggestion, Duration took)One mutant’s outcome.
Components
coveredBy | the tests that reach the mutant’s line, fastest first |
|---|---|
caughtBy | the test that failed, if one did |
failure | what it failed with: the exception’s class |
failureOrigin | where that came from: assertion (a check failed), test (the test’s own code threw) or code (the code under test threw) |
testsRun | how many covering tests ran before the result was known |
unconfirmed | a test whose catch didn’t repeat when run again, if catches were confirmed |
inputs | the whole numbers the covering tests passed to the mutant’s method, by parameter name: what the tests tried, so what they didn’t is plain |
suggestion | a call whose result the mutant changes, for a missed mutant, if one was found |
Methods
notCovered
static MutantResult notCovered(Mutant mutant)skipped
static MutantResult skipped(Mutant mutant)alsoCoveredBy
MutantResult alsoCoveredBy(List<String> tests)The same result, reached by tests too: another run’s, over the same mutant.
withSuggestion
MutantResult withSuggestion(Optional<Suggestion> found)The same result with a suggested test.