summaryrefslogtreecommitdiffstats
path: root/Lib/test/libregrtest
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2016-08-17 14:12:16 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2016-08-17 14:12:16 (GMT)
commit636860354ee7be4b7bf55dddb0cbb129c989b681 (patch)
tree604affd073ec6fc627f978c1d3fcbc0b6aaead62 /Lib/test/libregrtest
parentc5a01f8551743bdc006f574bad62a793654ce0ca (diff)
downloadcpython-636860354ee7be4b7bf55dddb0cbb129c989b681.zip
cpython-636860354ee7be4b7bf55dddb0cbb129c989b681.tar.gz
cpython-636860354ee7be4b7bf55dddb0cbb129c989b681.tar.bz2
regrtest: add a summary of the summary, "Result: xxx"
It's sometimes hard to check quickly if tests succeeded, failed or something bad happened. I added a final "Result: xxx" line which summarizes all outputs into a single line, written at the end (it should always be the last line of the output).
Diffstat (limited to 'Lib/test/libregrtest')
-rw-r--r--Lib/test/libregrtest/main.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/test/libregrtest/main.py b/Lib/test/libregrtest/main.py
index 0723c43..78c52bd 100644
--- a/Lib/test/libregrtest/main.py
+++ b/Lib/test/libregrtest/main.py
@@ -431,6 +431,14 @@ class Regrtest:
duration = time.monotonic() - self.start_time
print("Total duration: %s" % format_duration(duration))
+ if self.bad:
+ result = "FAILURE"
+ elif self.interrupted:
+ result = "INTERRUPTED"
+ else:
+ result = "SUCCESS"
+ print("Result: %s" % result)
+
if self.ns.runleaks:
os.system("leaks %d" % os.getpid())