Merge from 3.5 for issue #25188.
diff --git a/Lib/test/libregrtest/main.py b/Lib/test/libregrtest/main.py
index 30d8a59..aa95b21 100644
--- a/Lib/test/libregrtest/main.py
+++ b/Lib/test/libregrtest/main.py
@@ -103,7 +103,10 @@
def display_progress(self, test_index, test):
if self.ns.quiet:
return
- fmt = "[{1:{0}}{2}/{3}] {4}" if self.bad else "[{1:{0}}{2}] {4}"
+ if self.bad and not self.ns.pgo:
+ fmt = "[{1:{0}}{2}/{3}] {4}"
+ else:
+ fmt = "[{1:{0}}{2}] {4}"
print(fmt.format(self.test_count_width, test_index,
self.test_count, len(self.bad), test),
flush=True)
@@ -238,6 +241,11 @@
print(count(len(omitted), "test"), "omitted:")
printlist(omitted)
+ # If running the test suite for PGO then no one cares about
+ # results.
+ if self.ns.pgo:
+ return
+
if self.good and not self.ns.quiet:
if (not self.bad
and not self.skipped
@@ -314,7 +322,7 @@
# For a partial run, we do not need to clutter the output.
if (self.ns.verbose
or self.ns.header
- or not (self.ns.quiet or self.ns.single
+ or not (self.ns.pgo or self.ns.quiet or self.ns.single
or self.tests or self.ns.args)):
# Print basic platform information
print("==", platform.python_implementation(), *sys.version.split())