I just discovered that the NUnit Add-In in MonoDevelop has a nice although undocumented feature: you can specify a custom test runner in the .csproj file, either as an executable or as a type. If you have the
NUnit.Runners nuget package installed in your solution/project and you want MonoDevelop to run the unit tests with
nunit-console.exe instead of the built-in runner, you can add the following to your .csproj file:
</PropertyGroup> <TestRunnerCommand>packages/NUnit.Runners.Net126.96.36.199/tools/nunit-console.exe</TestRunnerCommand> </PropertyGroup>
Now when you run your unit tests in MonoDevelop they will be run by nunit-console. This is useful when your unit tests make use of features that the NUnit Add-in doesn’t support yet, like ActionAttributes.
The other tags that are supported are:
TestRunnerArgs: Allows to specify additional command line arguments to the
TestRunnerAssembly: allow to specify a test runner class/type and the assembly where to find this type.
TestRunnerType are specified,
TestRunnerArgs takes precedence.