summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2012-07-11 17:21:31 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2012-07-11 17:21:31 (GMT)
commit673eb6a0bbf9708d89ead5ca4c0e5a5c349b79dd (patch)
tree48b190afb6cf3c53dc6a5c134543d60c917942de
parentfa0989fd38b9e01ec62db7b1c6ed2847628913e4 (diff)
parent282083d5f4f5a0ba02cf0149caec06a6afecdb5e (diff)
downloadcpython-673eb6a0bbf9708d89ead5ca4c0e5a5c349b79dd.zip
cpython-673eb6a0bbf9708d89ead5ca4c0e5a5c349b79dd.tar.gz
cpython-673eb6a0bbf9708d89ead5ca4c0e5a5c349b79dd.tar.bz2
Issue #15300: Ensure the temporary test working directories are in the same parent folder when running tests in multiprocess mode from a Python build.
Patch by Chris Jerdonek.
-rwxr-xr-xLib/test/regrtest.py6
-rw-r--r--Misc/ACKS1
-rw-r--r--Misc/NEWS4
3 files changed, 10 insertions, 1 deletions
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py
index beb2ba8..28655f0 100755
--- a/Lib/test/regrtest.py
+++ b/Lib/test/regrtest.py
@@ -634,10 +634,14 @@ def main(tests=None, testdir=None, verbose=0, quiet=False,
output.put((None, None, None, None))
return
# -E is needed by some tests, e.g. test_import
+ # Running the child from the same working directory ensures
+ # that TEMPDIR for the child is the same when
+ # sysconfig.is_python_build() is true. See issue 15300.
popen = Popen(base_cmd + ['--slaveargs', json.dumps(args_tuple)],
stdout=PIPE, stderr=PIPE,
universal_newlines=True,
- close_fds=(os.name != 'nt'))
+ close_fds=(os.name != 'nt'),
+ cwd=support.SAVEDCWD)
stdout, stderr = popen.communicate()
retcode = popen.wait()
# Strip last refcount output line if it exists, since it
diff --git a/Misc/ACKS b/Misc/ACKS
index 62d3e01..a35fd74 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -505,6 +505,7 @@ Julien Jehannet
Drew Jenkins
Flemming Kjær Jensen
MunSic Jeong
+Chris Jerdonek
Jim Jewett
Orjan Johansen
Fredrik Johansson
diff --git a/Misc/NEWS b/Misc/NEWS
index f48bb7d..25f240c 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -121,6 +121,10 @@ Documentation
Tests
-----
+- Issue #15300: Ensure the temporary test working directories are in the same
+ parent folder when running tests in multiprocess mode from a Python build.
+ Patch by Chris Jerdonek.
+
- Issue #15284: Skip {send,recv}msg tests in test_socket when IPv6 is not
enabled. Patch by Brian Brazil.