Switch test_autokill back to subprocess.Popen - os.spawn uses fork internally, even on Python 3.

This commit is contained in:
Pavel Minaev 2018-11-08 15:01:25 -08:00
parent c9c6417788
commit 9bedbedd4e

View file

@ -198,6 +198,8 @@ def test_subprocess(debug_session, pyfile):
@pytest.mark.timeout(60)
@pytest.mark.skipif(sys.version_info < (3, 0) and (platform.system() != 'Windows'),
reason='Bug #935')
def test_autokill(debug_session, pyfile):
@pyfile
def child():
@ -208,8 +210,11 @@ def test_autokill(debug_session, pyfile):
def parent():
import backchannel
import os
import subprocess
import sys
os.spawnl(os.P_NOWAIT, sys.executable, sys.executable, sys.argv[1])
argv = [sys.executable, sys.argv[1]]
env = os.environ.copy()
subprocess.Popen(argv, env=env, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
backchannel.read_json()
debug_session.multiprocess = True