From 37067a53c4b3b99982ef8e1f431ba0c9302b66e8 Mon Sep 17 00:00:00 2001 From: Xavier Claessens Date: Sun, 13 May 2018 10:36:58 -0400 Subject: Use a single ArgumentParser for all subcommands This has the adventage that "meson --help" shows a list of all commands, making them discoverable. This also reduce the manual parsing of arguments to the strict minimum needed for backward compatibility. --- run_project_tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'run_project_tests.py') diff --git a/run_project_tests.py b/run_project_tests.py index ba7b5e0..876d135 100755 --- a/run_project_tests.py +++ b/run_project_tests.py @@ -247,12 +247,12 @@ def run_test_inprocess(testdir): os.chdir(testdir) test_log_fname = Path('meson-logs', 'testlog.txt') try: - returncode_test = mtest.run(['--no-rebuild']) + returncode_test = mtest.run_with_args(['--no-rebuild']) if test_log_fname.exists(): test_log = test_log_fname.open(errors='ignore').read() else: test_log = '' - returncode_benchmark = mtest.run(['--no-rebuild', '--benchmark', '--logbase', 'benchmarklog']) + returncode_benchmark = mtest.run_with_args(['--no-rebuild', '--benchmark', '--logbase', 'benchmarklog']) finally: sys.stdout = old_stdout sys.stderr = old_stderr -- cgit v1.1