I am having NUnit/.NET solution with following structure:
solutionDir/Integration/Integration.Suite1.Tests/all files including .csproj
solutionDir/Integration/Integration.Suite2.Tests/all files including .csproj
solutionDir/Integration/Integration.Suite3.Tests/all files including .csproj
solutionDir/Tests/Unit.Suite1.Tests/all files including .csproj
solutionDir/Tests/Unit.Suite2.Tests/all files including .csproj
solutionDir/Tests/Unit.Suite3.Tests/all files including .csproj
solutionDir/Tests/Unit.Suite4.Tests/all files including .csproj
solutionDir/Tests/Unit.Suite5.Tests/all files including .csproj
They all can be run in parallel and we are supporting it using appropriate attributes (including AssemblyInfo.cs changes) - without them it takes ~15 minutes, even locally
Running all of them are taking:
~2 minutes using Visual Studio NUnit runner
~1:30 using nunit3-console on local machine
~2 minutes using TeamCity build Command Line step (%toolsPath%\NUnit.ConsoleRunner\tools\nunit3-console.exe path to csproj file 1 ... path to csproj file last /config:Release)
~10-15 minutes using NUnit runner
How can we configure NUnit runner to be faster. I observed it builds multiple .nunit files in artifacts and process them in series instead in parallel.
Using nunit_use_project_file doesn't fix anything.
My step is configured as default, with Run test from set as **\bin\%system.Configuration%\*.Tests.dll, where %system.Configuration% is Release.
What is very important, above NUit run I need to have code coverage done as well.