asyncio: Sync with upstream (compat module)

This commit is contained in:
Yury Selivanov 2015-08-04 15:56:33 -04:00
parent 996083d6e6
commit 2a8911c0b7
7 changed files with 14 additions and 16 deletions

View file

@ -417,11 +417,7 @@ class SubprocessMixin:
def test_popen_error(self):
# Issue #24763: check that the subprocess transport is closed
# when BaseSubprocessTransport fails
if sys.platform == 'win32':
target = 'asyncio.windows_utils.Popen'
else:
target = 'subprocess.Popen'
with mock.patch(target) as popen:
with mock.patch('subprocess.Popen') as popen:
exc = ZeroDivisionError
popen.side_effect = exc