@@ -572,6 +572,7 @@ def main(tests=None, testdir=None, verbose=0, quiet=False,
572
572
nottests .add (arg )
573
573
args = []
574
574
575
+ display_header = (verbose or header or not (quiet or single or tests or args )) and (not pgo )
575
576
alltests = findtests (testdir , stdtests , nottests )
576
577
selected = tests or args or alltests
577
578
if single :
@@ -657,18 +658,17 @@ def display_progress(test_index, test):
657
658
sys .stdout .flush ()
658
659
659
660
# For a partial run, we do not need to clutter the output.
660
- if verbose or header or not (quiet or single or tests or args ):
661
- if not pgo :
662
- # Print basic platform information
663
- print "==" , platform .python_implementation (), \
664
- " " .join (sys .version .split ())
665
- print "== " , platform .platform (aliased = True ), \
666
- "%s-endian" % sys .byteorder
667
- print "== " , os .getcwd ()
668
- ncpu = cpu_count ()
669
- if ncpu :
670
- print "== CPU count:" , ncpu
671
- print "Testing with flags:" , sys .flags
661
+ if display_header :
662
+ # Print basic platform information
663
+ print "==" , platform .python_implementation (), \
664
+ " " .join (sys .version .split ())
665
+ print "== " , platform .platform (aliased = True ), \
666
+ "%s-endian" % sys .byteorder
667
+ print "== " , os .getcwd ()
668
+ ncpu = cpu_count ()
669
+ if ncpu :
670
+ print "== CPU count:" , ncpu
671
+ print "Testing with flags:" , sys .flags
672
672
673
673
if randomize :
674
674
random .seed (random_seed )
0 commit comments