Commits

Florent Xicluna committed 966eb1b

Print platform information to stdout, to help troubleshooting platform-specific failures.

  • Participants
  • Parent commits 5b17643
  • Branches legacy-trunk

Comments (0)

Files changed (1)

File Lib/test/regrtest.py

 import unittest
 import tempfile
 import imp
+import platform
 import sysconfig
 
 
         usage(2, "-T and -j don't go together!")
     if use_mp and findleaks:
         usage(2, "-l and -j don't go together!")
+    if use_mp and max(sys.flags):
+        # TODO: inherit the environment and the flags
+        print "Warning: flags and environment variables are ignored with -j option"
 
     good = []
     bad = []
     resource_denieds = []
     environment_changed = []
 
-    if verbose:
-        print 'The CWD is now', os.getcwd()
+    if not quiet:
+        # Print basic platform information
+        print "== {} {}".format(
+            platform.python_implementation(),
+            " ".join(sys.version.split())
+        )
+        print "==   {}".format(platform.platform(aliased=True))
+        print "==   {}".format(os.getcwd())
 
     if findleaks:
         try: