3
from tests.patcher_test import ProcessBase
4
from tests import skip_with_pyevent
5
from eventlet.green import subprocess
7
class Subprocess(ProcessBase):
8
def test_longoutput(self):
16
filename = modname + ".py"
17
self.write_to_tempfile(modname, new_mod)
18
python_path = os.pathsep.join(sys.path + [self.tempdir])
19
new_env = os.environ.copy()
20
new_env['PYTHONPATH'] = python_path
21
p = subprocess.Popen([sys.executable,
22
os.path.join(self.tempdir, filename)],
23
stdout=subprocess.PIPE, stderr=subprocess.STDOUT, env=new_env)
24
output, _ = p.communicate()
25
self.assertEqual(output, "*"*10000 + " " + "*"*10000 + "\n")