Skip to content

Commit 1eeaf49

Browse files
committed
Added an error exit when the test runner is invoked with incompatible switches (--parallel and --html-report)
- Legacy-Id: 14024
1 parent 0a0ac78 commit 1eeaf49

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

ietf/utils/test_runner.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,10 @@ def __init__(self, skip_coverage=False, save_version_coverage=None, html_report=
468468
self.coverage_file = os.path.join(self.root_dir, settings.TEST_COVERAGE_MASTER_FILE)
469469
super(IetfTestRunner, self).__init__(**kwargs)
470470
if self.parallel > 1:
471+
if self.html_report == True:
472+
sys.stderr.write("The switches --parallel and --html-report cannot be combined, "
473+
"as the collection of test coverage data isn't currently threadsafe.")
474+
sys.exit(1)
471475
self.check_coverage = False
472476

473477
def setup_test_environment(self, **kwargs):

0 commit comments

Comments
 (0)