]> granicus.if.org Git - python/commitdiff
bpo-30223: Add global in regrtest main_in_temp_cwd (#1399)
authorVictor Stinner <victor.stinner@gmail.com>
Tue, 2 May 2017 21:43:25 +0000 (23:43 +0200)
committerGitHub <noreply@github.com>
Tue, 2 May 2017 21:43:25 +0000 (23:43 +0200)
Lib/test/regrtest.py

index cbd9185257c71563f35dbf383bfd7ddf96093c69..5702e38f457c6f311716f39d0845a609a535cc1b 100755 (executable)
@@ -1647,6 +1647,8 @@ class _ExpectedSkips:
 
 def main_in_temp_cwd():
     """Run main() in a temporary working directory."""
+    global TEMPDIR
+
     # When tests are run from the Python build directory, it is best practice
     # to keep the test files in a subfolder.  It eases the cleanup of leftover
     # files using command "make distclean".