MutationTestBuilder Fluent Interface
Provides the name of the method that is under test. This is set up on your regular tests using the
attribute. This is a mandatory
method name and is implemented as a static method for
- methodName: case sensitive string identifying the method.
Executes the mutation testing. Iterates over all the possible mutations for the method that you have requested through other fluent methods. If this is the only other method other than For(), all possible mutations will be run. This should be the final method
in the chain, and returns void
Identfies a type of mutation testing to perform. Possible values for T
If the With<T>()
method is not applied to the chain, all the above mutations are run.
Identifies when a method is expected to be invariant for a particular type of mutator.
is expected to be of type IMethodTurtle
and can be any of the following:
In the example SimpleCalculator
solution, the Add
method is invariant on
since addition is not order dependant. Subtraction however is.
Overloaded method for ExpectedInvariantFor<T>()
providing a reason for the invariant nature.
This method allows you to implement your own mutator and combine it with the existing built in mutations.
Identifies the type of runner to use when running the mutation tests. Possible values for
By default, the NUnitTestRunner
will be used.