From 9a15a46df57217125d4cc6b205b5a1c0d7ef6eee Mon Sep 17 00:00:00 2001 From: James Prestwood Date: Thu, 12 Aug 2021 13:21:52 -0700 Subject: [PATCH] test-runner: don't fatally exit on bad test configuration If a test has no hw.conf file test-runner was fully exiting and not running any additional tests. This shouldn't happen in practice since all upstreamed tests should run, but if any locally created tests existed like this, it would cause the entire test run to exit early. Instead raise an exception which bails out of only that test, and allows the rest to continue. --- tools/test-runner | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/test-runner b/tools/test-runner index 7e789dd7..939efa51 100755 --- a/tools/test-runner +++ b/tools/test-runner @@ -1072,8 +1072,7 @@ def pre_test(ctx, test, copied): dbg("Starting test %s" % test) if not os.path.exists(test + '/hw.conf'): - print("No hw.conf found for %s" % test) - exit() + raise Exception("No hw.conf found for %s" % test) ctx.hw_config = ConfigParser() ctx.hw_config.read(test + '/hw.conf')