From ed5f7ccb9c93946913ac3ecc4132bf8e42260fd3 Mon Sep 17 00:00:00 2001 From: Alan Bram Date: Tue, 6 Apr 2021 13:31:04 -0700 Subject: Show "FAILURE in exit code" when success is expected Fixes #2023. --- test/RegressTests.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'test') diff --git a/test/RegressTests.py b/test/RegressTests.py index 7395a4c1..b20c0aa6 100755 --- a/test/RegressTests.py +++ b/test/RegressTests.py @@ -182,7 +182,7 @@ class RegressFile(object): printed = True print(" ", line,) - if test['exitcode'] is None or test['exitcode'] == p.wait(): + if test['exitcode'] == p.wait(): if success: harness.success() else: @@ -191,10 +191,9 @@ class RegressFile(object): print(p.stderr.read()) else: if success: print - if test['exitcode']: - self.notify_user("FAILURE in exit code (%d != %d) from %s:" - % (test['exitcode'], p.returncode, self.filename), - test) + self.notify_user("FAILURE in exit code (%d != %d) from %s:" + % (test['exitcode'], p.returncode, self.filename), + test) harness.failure(os.path.basename(self.filename)) def run_tests(self): -- cgit v1.2.3