diff options
author | Zac Medico <zmedico@gentoo.org> | 2010-08-06 17:34:09 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-08-06 17:34:09 -0700 |
commit | 67797d2ed2914b5eb805e096904fd34ace78f74f (patch) | |
tree | e7d8985606269cca58fa549250f4964df899784b | |
parent | ac6ee1217d2309cbc2ab4af893f57fc5b76eaeb2 (diff) | |
download | portage-67797d2ed2914b5eb805e096904fd34ace78f74f.tar.gz portage-67797d2ed2914b5eb805e096904fd34ace78f74f.tar.bz2 portage-67797d2ed2914b5eb805e096904fd34ace78f74f.zip |
Use ResolverPlayground for it's config instance, so that we don't
instantiate portage.settings.
-rw-r--r-- | pym/portage/tests/ebuild/test_spawn.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/pym/portage/tests/ebuild/test_spawn.py b/pym/portage/tests/ebuild/test_spawn.py index f37a0c5a3..bb9fb2623 100644 --- a/pym/portage/tests/ebuild/test_spawn.py +++ b/pym/portage/tests/ebuild/test_spawn.py @@ -4,16 +4,19 @@ import codecs import errno import sys +from tempfile import mkstemp from portage import os from portage import _encodings from portage import _unicode_encode +from portage import spawn from portage.tests import TestCase +from portage.tests.resolver.ResolverPlayground import ResolverPlayground class SpawnTestCase(TestCase): def testLogfile(self): - from portage import settings, spawn - from tempfile import mkstemp + playground = ResolverPlayground() + settings = playground.settings logfile = None try: fd, logfile = mkstemp() @@ -42,6 +45,7 @@ class SpawnTestCase(TestCase): # may occur. self.assertEqual(test_string, log_content) finally: + playground.cleanup() if logfile: try: os.unlink(logfile) |