bpo-40275: Use new test.support helper submodules in tests (GH-21448)

This commit is contained in:
Hai Shi 2020-08-04 00:49:18 +08:00 committed by GitHub
parent bb0424b122
commit 4660597b51
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 185 additions and 154 deletions

View file

@ -5,6 +5,7 @@
from test import test_tools
from test import support
from test.support import os_helper
from test.support.script_helper import assert_python_ok
test_tools.skip_if_missing("peg_generator")
@ -68,7 +69,7 @@ def setUp(self):
self.skipTest("The %r command is not found" % cmd)
super(TestCParser, self).setUp()
self.tmp_path = self.mkdtemp()
change_cwd = support.change_cwd(self.tmp_path)
change_cwd = os_helper.change_cwd(self.tmp_path)
change_cwd.__enter__()
self.addCleanup(change_cwd.__exit__, None, None, None)