diff options
author | juraj.linkes <juraj.linkes@pantheon.tech> | 2019-07-03 10:42:40 +0200 |
---|---|---|
committer | juraj.linkes <juraj.linkes@pantheon.tech> | 2019-07-03 11:40:58 +0200 |
commit | b5ef26d1ed524d1f2f59ffd5546d1c581f4c88a2 (patch) | |
tree | 7a4cb234ea126b565f8b2671e05b6a12242fcd33 /test | |
parent | b34f99ced80a8eeb8c4eba5e2d023d70f210253b (diff) |
tests: fix FORCE_FOREGROUND
Type: fix
Change-Id: I145f9984c1d944d5b7de0487e8b41ae4fdb95b6d
Signed-off-by: juraj.linkes <juraj.linkes@pantheon.tech>
Diffstat (limited to 'test')
-rw-r--r-- | test/run_tests.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/test/run_tests.py b/test/run_tests.py index 55b8123756c..58ca7d53e39 100644 --- a/test/run_tests.py +++ b/test/run_tests.py @@ -733,7 +733,10 @@ if __name__ == '__main__': step = os.getenv("STEP", "n").lower() in ("y", "yes", "1") - run_interactive = debug or step + force_foreground = os.getenv("FORCE_FOREGROUND", "").lower() in \ + ("y", "yes", "1") + + run_interactive = debug or step or force_foreground test_jobs = os.getenv("TEST_JOBS", "1").lower() # default = 1 process if test_jobs == 'auto': @@ -806,6 +809,7 @@ if __name__ == '__main__': if run_interactive and suites: # don't fork if requiring interactive terminal + print('Running tests in foreground in the current process') full_suite = unittest.TestSuite() map(full_suite.addTests, suites) result = VppTestRunner(verbosity=verbose, @@ -824,6 +828,8 @@ if __name__ == '__main__': sys.exit(not was_successful) else: + print('Running each VPPTestCase in a separate background process' + ' with {} parallel process(es)'.format(concurrent_tests)) exit_code = 0 while suites and attempts > 0: results = run_forked(suites) |