Documentation
¶
Overview ¶
Package confirminglaboratory re-runs a mutant that died by assertion, once.
Backlog entry 27. verifyBaseline is a sync.Once: it catches a suite that is already red before anything is scored, and refuses rather than reporting. It cannot catch one that goes red at mutant 37. With no retry anywhere, a spurious failure during a mutant run classified as verdict.Assertion and became a false kill indistinguishable from a real one in the report — the same defect as the compile-failure kill, arriving from the other direction.
It is opt-in, and the reason is cost: confirming doubles the price of every kill it applies to. What keeps that price arguable rather than obvious is that only ASSERTION kills can be flakes. A mutant that never built already leaves the score on both sides, and a deadline kill is one ditto fired its own clock for, so neither is re-run. The reported repository sees roughly one run in five go red on a cold suite; a repository that never flakes pays nothing for leaving this off, and nothing but time for turning it on.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New(logger ditto.Logger, delegate ditto.Laboratory) ditto.Laboratory
New returns a decorator that batches exactly when what it wraps does.
Types ¶
type ConfirmingLaboratory ¶
type ConfirmingLaboratory struct {
// contains filtered or unexported fields
}
ConfirmingLaboratory asks twice before it believes a kill.
func (*ConfirmingLaboratory) Test ¶
func (l *ConfirmingLaboratory) Test( repository ditto.Repository, file *gomutatedfile.GoMutatedFile, ) future.Future[result.Result[string]]