diff options
| author | Ezio Melotti <ezio.melotti@gmail.com> | 2011-05-23 22:01:08 (GMT) |
|---|---|---|
| committer | Ezio Melotti <ezio.melotti@gmail.com> | 2011-05-23 22:01:08 (GMT) |
| commit | 64af7c0d36ae78881b127643052d43316da9f52c (patch) | |
| tree | c47de0395f9f3b0d081a44af6d4978870cd10082 /Lib/test | |
| parent | 17ec7cd9ca28ae2e8320a740d00927dcaed67274 (diff) | |
| parent | 84f75c680c2a17954155e71455061599e8778ccb (diff) | |
| download | cpython-64af7c0d36ae78881b127643052d43316da9f52c.zip cpython-64af7c0d36ae78881b127643052d43316da9f52c.tar.gz cpython-64af7c0d36ae78881b127643052d43316da9f52c.tar.bz2 | |
#12074: merge with 3.2.
Diffstat (limited to 'Lib/test')
| -rwxr-xr-x | Lib/test/regrtest.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py index ccbe6f9..04e87e3 100755 --- a/Lib/test/regrtest.py +++ b/Lib/test/regrtest.py @@ -632,7 +632,8 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, continue accumulate_result(test, result) if not quiet: - print("[{1:{0}}{2}/{3}] {4}".format( + fmt = "[{1:{0}}{2}/{3}] {4}" if bad else "[{1:{0}}{2}] {4}" + print(fmt.format( test_count_width, test_index, test_count, len(bad), test)) if stdout: @@ -653,7 +654,8 @@ def main(tests=None, testdir=None, verbose=0, quiet=False, else: for test_index, test in enumerate(tests, 1): if not quiet: - print("[{1:{0}}{2}/{3}] {4}".format( + fmt = "[{1:{0}}{2}/{3}] {4}" if bad else "[{1:{0}}{2}] {4}" + print(fmt.format( test_count_width, test_index, test_count, len(bad), test)) sys.stdout.flush() if trace: |
