catch3
Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.
Clonegit clone https://git.progmasoft.com/catch3
Default to randomized test case order
- Commit
a483b6d7d36457b0931eca85fda1a30a2b56eb4e- Author
- Martin Hořeňovský ·
- Parents
b9c018b38a98
Changes
src/catch2/catch_config.hpp | 2 +- tests/TestScripts/testBazelSharding.py | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/catch2/catch_config.hpp b/src/catch2/catch_config.hpp index 17e983e5..b7b1315e 100644 --- a/src/catch2/catch_config.hpp +++ b/src/catch2/catch_config.hpp @@ -76,7 +76,7 @@ namespace Catch { WarnAbout::What warnings = WarnAbout::Nothing; ShowDurations showDurations = ShowDurations::DefaultForReporter; double minDuration = -1; - TestRunOrder runOrder = TestRunOrder::Declared; + TestRunOrder runOrder = TestRunOrder::Randomized; ColourMode defaultColourMode = ColourMode::PlatformDefault; WaitForKeypress::When waitForKeypress = WaitForKeypress::Never; diff --git a/tests/TestScripts/testBazelSharding.py b/tests/TestScripts/testBazelSharding.py index d4a9aeee..23594461 100755 --- a/tests/TestScripts/testBazelSharding.py +++ b/tests/TestScripts/testBazelSharding.py @@ -46,10 +46,15 @@ env["TEST_SHARD_INDEX"] = "0" env["TEST_TOTAL_SHARDS"] = "2" env["TEST_SHARD_STATUS_FILE"] = info_file_path +cmd = [ + bin_path, + # We rely on the test order being deterministic + '--order', 'decl' +] try: ret = subprocess.run( - bin_path, + cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, check=True,