0

I am trying to run a test that verifies the functionality of some system global state variables. For example: "enable feature A, test that feature A works, disable feature A, test that feature A no longer works". I cannot create a separate system for each test, so the state will be shared between tests.

The bulk of my tests do not touch this global state or depend on it and I want to parallelize as much as possible, is there a way (such as a mutex) to run most of the tests in parallel but a single test (or group of tests) as mutually exclusive with other tests related to the state?

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
BobtheMagicMoose
  • 2,246
  • 3
  • 19
  • 27

1 Answers1

0

One option is to run them all in one file, and either set the file to run in serial mode (though that mode isn’t recommended) or to use separate projects to match the separate files and set the fullyParallel option to false for that file’s project.

David R
  • 493
  • 2
  • 8