mirror of
https://github.com/python/cpython.git
synced 2025-07-15 23:35:23 +00:00
Syntax cleanup.
This commit is contained in:
parent
3f8ab965f7
commit
02ea12b291
7 changed files with 9 additions and 11 deletions
|
@ -86,7 +86,6 @@ class SysModuleTest(unittest.TestCase):
|
|||
# Python/pythonrun.c::PyErr_PrintEx() is tricky.
|
||||
|
||||
def test_exit(self):
|
||||
import subprocess
|
||||
|
||||
self.assertRaises(TypeError, sys.exit, 42, 42)
|
||||
|
||||
|
@ -529,7 +528,6 @@ class SysModuleTest(unittest.TestCase):
|
|||
sys._clear_type_cache()
|
||||
|
||||
def test_ioencoding(self):
|
||||
import subprocess
|
||||
env = dict(os.environ)
|
||||
|
||||
# Test character: cent sign, encoded as 0x4A (ASCII J) in CP424,
|
||||
|
@ -551,7 +549,7 @@ class SysModuleTest(unittest.TestCase):
|
|||
# Issue #7774: Ensure that sys.executable is an empty string if argv[0]
|
||||
# has been set to an non existent program name and Python is unable to
|
||||
# retrieve the real program name
|
||||
import subprocess
|
||||
|
||||
# For a normal installation, it should work without 'cwd'
|
||||
# argument. For test runs in the build directory, see #7774.
|
||||
python_dir = os.path.dirname(os.path.realpath(sys.executable))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue