diff options
author | Okke Formsma <okke@formsma.nl> | 2020-12-09 20:36:03 +0100 |
---|---|---|
committer | Pete Johanson <peter@peterjohanson.com> | 2020-12-10 11:41:42 -0500 |
commit | b4c0967645ab7b3952a3946663e16f02abf8a927 (patch) | |
tree | 54b71b83c59fef5a2c14368d3367be12553eb81b /app/scripts | |
parent | 5aa8a07aa9d15639e0315fef12d208040c739b7f (diff) |
fix(west) test command should not swallow errors.
Diffstat (limited to 'app/scripts')
-rw-r--r-- | app/scripts/west_commands/test.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/scripts/west_commands/test.py b/app/scripts/west_commands/test.py index b8f87c7..f79547b 100644 --- a/app/scripts/west_commands/test.py +++ b/app/scripts/west_commands/test.py @@ -4,6 +4,7 @@ '''Test runner for ZMK.''' import os +import subprocess from textwrap import dedent # just for nicer code indentation from west.commands import WestCommand @@ -30,4 +31,6 @@ class Test(WestCommand): def do_run(self, args, unknown_args): # the run-test script assumes the app directory is the current dir. os.chdir(f'{self.topdir}/app') - exit(os.system(f'{self.topdir}/app/run-test.sh {args.test_path}')) + completed_process = subprocess.run( + [f'{self.topdir}/app/run-test.sh', args.test_path]) + exit(completed_process.returncode) |