mirror of
https://github.com/python/cpython.git
synced 2025-09-15 05:06:12 +00:00
bpo-39763: distutils.spawn now uses subprocess (GH-18743)
Reimplement distutils.spawn.spawn() function with the subprocess module. setup.py now uses a basic implementation of the subprocess module if the subprocess module is not available: before required C extension modules are built.
This commit is contained in:
parent
dffe4c0709
commit
1ec63b6203
5 changed files with 87 additions and 117 deletions
|
@ -8,7 +8,6 @@ from test.support import run_unittest, unix_shell
|
|||
from test import support as test_support
|
||||
|
||||
from distutils.spawn import find_executable
|
||||
from distutils.spawn import _nt_quote_args
|
||||
from distutils.spawn import spawn
|
||||
from distutils.errors import DistutilsExecError
|
||||
from distutils.tests import support
|
||||
|
@ -17,16 +16,6 @@ class SpawnTestCase(support.TempdirManager,
|
|||
support.LoggingSilencer,
|
||||
unittest.TestCase):
|
||||
|
||||
def test_nt_quote_args(self):
|
||||
|
||||
for (args, wanted) in ((['with space', 'nospace'],
|
||||
['"with space"', 'nospace']),
|
||||
(['nochange', 'nospace'],
|
||||
['nochange', 'nospace'])):
|
||||
res = _nt_quote_args(args)
|
||||
self.assertEqual(res, wanted)
|
||||
|
||||
|
||||
@unittest.skipUnless(os.name in ('nt', 'posix'),
|
||||
'Runs only under posix or nt')
|
||||
def test_spawn(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue