In this article, it is mentioned that to speed up tests, the poster launches several instances of NUnit with command parameters that determine which tests each instance should run.
FTA:
I ran into an odd problem.
We use nunit-console to run a test on our continuous integration server. We recently moved from Nunit 2.4.8 to 2.5.5 and from .Net 3.5 to 4.0. To speed up the test, we run several Nunit instances in parallel with another command line. Arguments
- We have two copies of our test builds and nunit binaries in folders A and B.
- In folder A we execute
nunit-console-x86.exe Model.dll Test.dll / exclude: MyCategory / xml = TestResults.xml / framework = net-4.0 / noshadow
nunit-console-x86.exe Model.dll Test.dll / include: MyCategory / xml = TestResults.xml / framework = net-4.0 / noshadow
If we consistently execute commands, both work successfully. But if we execute them in parallel only one succeeds. As far as I can tell, this is the one that loads test fixtures first. Another does not work with the message “Could not find fixture”.
Is this problem known? I could not find anything related to the error list in the launcher. BTW Our server runs the 64-bit version of Windows Server 2008. I could also reproduce the problem in Windows 7 64-bit.
Assuming this bug is fixed or you are not using a newer version of the software mentioned, you should be able to replicate your technique.
Update
TeamCity looks like a tool that you can use to automatically run NUnit tests. They have a NUnit launcher discussed here , which can be used to run multiple instances of NUnit. Here is a blog post that discusses combining multiple NUnit XML results into a single result file.
Thus, in theory, you could force TeamCity to automatically run several NUnit tests based on the fact that you want to split the workload and then combine the results into a single file for further processing of the test.
How automated is it for your needs?
kniemczak Jul 27 2018-10-22T00: 00Z
source share