From ce698f3aa2e535685d0321709de7fa5d3f6de86f Mon Sep 17 00:00:00 2001 From: Zachary Ware Date: Sat, 8 Aug 2015 22:01:20 -0500 Subject: Issue #24751: Fix running regrtest with '-w' flag in case of test failures. Also fixes reporting of tests that change environment when there are no test failures. --- Lib/test/regrtest.py | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py index eaf39bb..9a8172c 100755 --- a/Lib/test/regrtest.py +++ b/Lib/test/regrtest.py @@ -624,14 +624,12 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, for time, test in test_times[:10]: print "%s: %.1fs" % (test, time) if bad: - bad = set(bad) - set(environment_changed) - if bad: - print count(len(bad), "test"), "failed:" - printlist(bad) - if environment_changed: - print "{} altered the execution environment:".format( - count(len(environment_changed), "test")) - printlist(environment_changed) + print count(len(bad), "test"), "failed:" + printlist(bad) + if environment_changed: + print "{} altered the execution environment:".format( + count(len(environment_changed), "test")) + printlist(environment_changed) if skipped and not quiet: print count(len(skipped), "test"), "skipped:" printlist(skipped) -- cgit v0.12