Parallel test running in Resharper with xUnit tests

As I understand from xUnit documentation that logic to decide which tests will be run in parallel, is in test framework, in xUnit case it is xUnit code.

"When we say "Parallelism in Test Frameworks", what we mean specifically is how a test framework may choose to support running tests within a single assembly in parallel with one another"

Then we have test runner framework which can have own logic to decide which tests run in parallel.

""Parallelism in Runners", we mean how a test runner may choose to support running test assemblies in parallel against each other"

Then about xUnit 2.0:

How does decide which tests can run against each other in parallel? It uses a concept called test collections to make that decision.

By default, each test class is a unique test collection. Tests within the same test class will not run in parallel against each other.


So every test class will be executed in parallel, Actually Bunch of test classes based on max of threads and cores on computer. 

All I found from Resharper documentations and other articles/forums that Resharper test runner can run in parallel only on assembly level. So my question is there possibility to run tests in parallel on the class level in Resharper?



1 comment
Comment actions Permalink

According to xUnit philosophy, code itself should manifest which tests are safe to execute in parallel - see xUnit test collections.

By default all tests considered safe to run in parallel, this can be overridden via assembly attribute: 

[assembly: Xunit.CollectionBehavior(MaxParallelThreads = 1)]


Please sign in to leave a comment.