mirror of
https://github.com/python/cpython.git
synced 2025-08-30 05:35:08 +00:00
The _posixsubprocess module is now required on POSIX.
Remove the pure Python POSIX subprocess implementation. If non-CPython VMs (are there any for 3.x yet?) were somehow depending on this, they already have the exact same set of problems with Python code being executed after os.fork() that _posixsubprocess was written to deal with. They should implement an equivalent outside of Python.
This commit is contained in:
parent
c80504fb69
commit
59fd1bfcc1
2 changed files with 27 additions and 181 deletions
|
@ -1495,28 +1495,6 @@ class ProcessTestCaseNoPoll(ProcessTestCase):
|
|||
ProcessTestCase.tearDown(self)
|
||||
|
||||
|
||||
@unittest.skipUnless(getattr(subprocess, '_posixsubprocess', False),
|
||||
"_posixsubprocess extension module not found.")
|
||||
class ProcessTestCasePOSIXPurePython(ProcessTestCase, POSIXProcessTestCase):
|
||||
@classmethod
|
||||
def setUpClass(cls):
|
||||
global subprocess
|
||||
assert subprocess._posixsubprocess
|
||||
# Reimport subprocess while forcing _posixsubprocess to not exist.
|
||||
with support.check_warnings(('.*_posixsubprocess .* not being used.*',
|
||||
RuntimeWarning)):
|
||||
subprocess = support.import_fresh_module(
|
||||
'subprocess', blocked=['_posixsubprocess'])
|
||||
assert not subprocess._posixsubprocess
|
||||
|
||||
@classmethod
|
||||
def tearDownClass(cls):
|
||||
global subprocess
|
||||
# Reimport subprocess as it should be, restoring order to the universe.
|
||||
subprocess = support.import_fresh_module('subprocess')
|
||||
assert subprocess._posixsubprocess
|
||||
|
||||
|
||||
class HelperFunctionTests(unittest.TestCase):
|
||||
@unittest.skipIf(mswindows, "errno and EINTR make no sense on windows")
|
||||
def test_eintr_retry_call(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue