From: Tarek Ziadé Date: Mon, 12 Apr 2010 08:23:49 +0000 (+0000) Subject: Fixed #8375 - test_distutils now checks what remains to be cleaned up during tearDown X-Git-Tag: v3.2a1~1169 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=46cd93a42f917bcd0a1cc7ca62eec55e56331d6f;p=thirdparty%2FPython%2Fcpython.git Fixed #8375 - test_distutils now checks what remains to be cleaned up during tearDown --- diff --git a/Lib/distutils/tests/support.py b/Lib/distutils/tests/support.py index d60da854be91..45c94411eee7 100644 --- a/Lib/distutils/tests/support.py +++ b/Lib/distutils/tests/support.py @@ -63,6 +63,8 @@ class TempdirManager(object): super().tearDown() while self.tempdirs: d = self.tempdirs.pop() + if not os.path.exists(d): + continue shutil.rmtree(d, os.name in ('nt', 'cygwin')) def mkdtemp(self): diff --git a/Misc/NEWS b/Misc/NEWS index 7d5fefe29c41..0ca4bd3194b7 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -312,6 +312,9 @@ C-API Library ------- +- Issue #8375: test_distutils now checks if the temporary directory are still + present before it cleans them. + - Issue #8374: Update the internal alias table in the :mod:`locale` module to cover recent locale changes and additions.