summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/tests/support.py
diff options
context:
space:
mode:
authorTarek Ziadé <ziade.tarek@gmail.com>2009-05-10 12:02:35 (GMT)
committerTarek Ziadé <ziade.tarek@gmail.com>2009-05-10 12:02:35 (GMT)
commit29bbb9618da442f4b4c0cc19a4d68b0b24531e24 (patch)
treee375a71a6b0e51516b82b6acf1c5554619c71a56 /Lib/distutils/tests/support.py
parentc27aca7d3ce46c5a479ac91db5ae4c0ea92ecc6a (diff)
downloadcpython-29bbb9618da442f4b4c0cc19a4d68b0b24531e24.zip
cpython-29bbb9618da442f4b4c0cc19a4d68b0b24531e24.tar.gz
cpython-29bbb9618da442f4b4c0cc19a4d68b0b24531e24.tar.bz2
Merged revisions 72539 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r72539 | tarek.ziade | 2009-05-10 13:59:30 +0200 (Sun, 10 May 2009) | 1 line refactored test_sysconfig so it uses test.test_support.EnvironmentVarGuard ........
Diffstat (limited to 'Lib/distutils/tests/support.py')
-rw-r--r--Lib/distutils/tests/support.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/Lib/distutils/tests/support.py b/Lib/distutils/tests/support.py
index ab2af9a..cdcbc37 100644
--- a/Lib/distutils/tests/support.py
+++ b/Lib/distutils/tests/support.py
@@ -5,6 +5,7 @@ import tempfile
from distutils import log
from distutils.core import Distribution
+from test.support import EnvironmentVarGuard
class LoggingSilencer(object):
@@ -82,3 +83,13 @@ class DummyCommand:
def ensure_finalized(self):
pass
+
+class EnvironGuard(object):
+
+ def setUp(self):
+ super(EnvironGuard, self).setUp()
+ self.environ = EnvironmentVarGuard()
+
+ def tearDown(self):
+ self.environ.__exit__()
+ super(EnvironGuard, self).tearDown()