From de52a2e2594e68c9abe33e31d63677e1c483d35a Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 14 Mar 2015 12:12:01 +0200 Subject: [PATCH] tests: Fix parallel-vm.py test case name parsing The 'params' argument was not used at all. Use it as an alternative means for setting the list of test cases to execute. Signed-off-by: Jouni Malinen --- tests/hwsim/vm/parallel-vm.py | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/tests/hwsim/vm/parallel-vm.py b/tests/hwsim/vm/parallel-vm.py index 4622512c2..ae43fe0aa 100755 --- a/tests/hwsim/vm/parallel-vm.py +++ b/tests/hwsim/vm/parallel-vm.py @@ -357,15 +357,19 @@ def main(): codecov = False first_run_failures = [] - tests = [] - cmd = [ os.path.join(os.path.dirname(scriptsdir), 'run-tests.py'), '-L' ] - if args.testmodules: - cmd += [ "-f" ] - cmd += args.testmodules - lst = subprocess.Popen(cmd, stdout=subprocess.PIPE) - for l in lst.stdout.readlines(): - name = l.split(' ')[0] - tests.append(name) + if args.params: + tests = args.params + else: + tests = [] + cmd = [ os.path.join(os.path.dirname(scriptsdir), 'run-tests.py'), + '-L' ] + if args.testmodules: + cmd += [ "-f" ] + cmd += args.testmodules + lst = subprocess.Popen(cmd, stdout=subprocess.PIPE) + for l in lst.stdout.readlines(): + name = l.split(' ')[0] + tests.append(name) if len(tests) == 0: sys.exit("No test cases selected")