]> granicus.if.org Git - python/commit
bpo-30028: make test.support.temp_cwd() fork-safe (GH-1066)
authorAnselm Kruis <a.kruis@science-computing.de>
Fri, 23 Feb 2018 01:37:38 +0000 (02:37 +0100)
committerGregory P. Smith <greg@krypto.org>
Fri, 23 Feb 2018 01:37:38 +0000 (17:37 -0800)
commit33dddac00ba8d9b72cf21b8698504077eb3c23ad
tree40893955f445131d96c340493afd027cfcaa66f5
parent520b7ae27e39d1c77ea74ccd1b184d7cb43f9dcb
bpo-30028: make test.support.temp_cwd() fork-safe (GH-1066)

Make test.support.temp_cwd() fork-safe. The context manager test.support.temp_cwd() no longer removes the temporary directory when executing in a process other than the parent it entered from.
If a forked child exits the context manager it won't do the cleanup.
Lib/test/support/__init__.py
Lib/test/test_support.py
Misc/ACKS