diff options
-rwxr-xr-x | run_tests.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/run_tests.py b/run_tests.py index 5fb9316..afaa7e6 100755 --- a/run_tests.py +++ b/run_tests.py @@ -19,6 +19,7 @@ import os, subprocess, shutil test_build_dir = 'work area' builder_command = './builder.py' +compile_command = os.path.join(test_build_dir, 'compile.sh') def run_test(testdir): shutil.rmtree(test_build_dir) @@ -27,7 +28,11 @@ def run_test(testdir): p = subprocess.Popen([builder_command, testdir, test_build_dir]) p.wait() if p.returncode != 0: - raise RuntimeError('Test failed.') + raise RuntimeError('Generating the build system failed.') + pc = subprocess.Popen([compile_command]) + pc.wait() + if pc.returncode != 0: + raise RuntimeError('Compiling source code failed.') def run_tests(): tests = glob('test cases/*') |