summaryrefslogtreecommitdiffstats
path: root/run_tests
diff options
context:
space:
mode:
Diffstat (limited to 'run_tests')
-rwxr-xr-xrun_tests5
1 files changed, 2 insertions, 3 deletions
diff --git a/run_tests b/run_tests
index f72b22c5..1b35aded 100755
--- a/run_tests
+++ b/run_tests
@@ -27,14 +27,13 @@ import sys
27def run_pytest(cmd, argv): 27def run_pytest(cmd, argv):
28 """Run the unittests via |cmd|.""" 28 """Run the unittests via |cmd|."""
29 try: 29 try:
30 subprocess.check_call([cmd] + argv) 30 return subprocess.call([cmd] + argv)
31 return 0
32 except OSError as e: 31 except OSError as e:
33 if e.errno == errno.ENOENT: 32 if e.errno == errno.ENOENT:
34 print('%s: unable to run `%s`: %s' % (__file__, cmd, e), file=sys.stderr) 33 print('%s: unable to run `%s`: %s' % (__file__, cmd, e), file=sys.stderr)
35 print('%s: Try installing pytest: sudo apt-get install python-pytest' % 34 print('%s: Try installing pytest: sudo apt-get install python-pytest' %
36 (__file__,), file=sys.stderr) 35 (__file__,), file=sys.stderr)
37 return 1 36 return 127
38 else: 37 else:
39 raise 38 raise
40 39