summaryrefslogtreecommitdiffstats
path: root/Lib/distutils
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2011-08-25 16:32:02 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2011-08-25 16:32:02 (GMT)
commit08e544e27bcc26fd82d218ea0676da42c8b8b9f7 (patch)
treea63c33e0584cf18dad0937d7cd3c88bf67aee516 /Lib/distutils
parentb0993bc78d976a91d1dc4d0ef9a207e1be38610f (diff)
downloadcpython-08e544e27bcc26fd82d218ea0676da42c8b8b9f7.zip
cpython-08e544e27bcc26fd82d218ea0676da42c8b8b9f7.tar.gz
cpython-08e544e27bcc26fd82d218ea0676da42c8b8b9f7.tar.bz2
Issue #12333: fix test_distutils failures under Solaris and derivativesv3.2.2
Diffstat (limited to 'Lib/distutils')
-rw-r--r--Lib/distutils/tests/support.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/distutils/tests/support.py b/Lib/distutils/tests/support.py
index 7a76ca0..8452feb 100644
--- a/Lib/distutils/tests/support.py
+++ b/Lib/distutils/tests/support.py
@@ -54,9 +54,13 @@ class TempdirManager(object):
def setUp(self):
super().setUp()
+ self.old_cwd = os.getcwd()
self.tempdirs = []
def tearDown(self):
+ # Restore working dir, for Solaris and derivatives, where rmdir()
+ # on the current directory fails.
+ os.chdir(self.old_cwd)
super().tearDown()
while self.tempdirs:
d = self.tempdirs.pop()