Console runner

NinjaTurtles comes with a command line, or console, runner for quick access to the power of mutation testing.

Finding the console runner

If you have installed the NinjaTurtles package from NuGet, then you will find the console runner with all its dependencies in the tools folder within the package. If you have downloaded the binaries from CodePlex, then you’ll find the console runner in the root of the folder structure when you unzip.

Getting started

We strongly recommend adding the folder containing the NinjaTurtles.Console runner to your environment’s PATH variable, or copying the executable with its dependencies to a folder that is already there.

Once you’ve done this, you can verify the installation by typing NinjaTurtles.Console help at the command prompt:

Console runner output

Running mutation tests

Mutation tests are run with a target class and/or method. Here’s an example which runs mutation tests against the TestDirectory class within NinjaTurtles itself:

Console runner output

You can get more informative output from the console runner in three ways. Firstly, it accepts a -v or --verbose option on the command line, which could be useful if you are capturing this output as part of a build log. Alternatively, you can produce structured output by using the -o or --output option. This will produce an XML file, and if you combine it with the -f HTML or -format HTML option, you get a nice HTML output file. Here’s that in full, and you can click here to see the output:

Console runner output