diff tests/run-tests.py @ 41178:53327bfbf35d

testrunner: make `-j100 --runs-per-test=100 test-foo.t` use 100 jobs It would use only 1 job since 1039404c5e1d (run-tests: print number of tests and parallel process count, 2018-10-13), but I'm pretty sure that was unintentional. Differential Revision: https://phab.mercurial-scm.org/D5557
author Martin von Zweigbergk <martinvonz@google.com>
date Thu, 10 Jan 2019 14:32:36 -0800
parents 89d103fc9c19
children 4f0ae5c64c1b
line wrap: on
line diff
--- a/tests/run-tests.py	Sun Jan 06 23:37:13 2019 -0800
+++ b/tests/run-tests.py	Thu Jan 10 14:32:36 2019 -0800
@@ -2859,8 +2859,9 @@
                     testdescs = orig
 
             tests = [self._gettest(d, i) for i, d in enumerate(testdescs)]
-
-            jobs = min(len(tests), self.options.jobs)
+            num_tests = len(tests) * self.options.runs_per_test
+
+            jobs = min(num_tests, self.options.jobs)
 
             failed = False
             kws = self.options.keywords
@@ -2897,7 +2898,7 @@
                     self._installchg()
 
                 log('running %d tests using %d parallel processes' % (
-                    len(tests), jobs))
+                    num_tests, jobs))
 
                 result = runner.run(suite)