MCPcopy Index your code
hub / github.com/python/cpython / run_test_in_subprocess

Method run_test_in_subprocess

Lib/test/test_audit.py:22–31  ·  view source on GitHub ↗
(self, *args)

Source from the content-addressed store, hash-verified

20
21 @support.requires_subprocess()
22 def run_test_in_subprocess(self, *args):
23 with subprocess.Popen(
24 [sys.executable, "-X utf8", AUDIT_TESTS_PY, *args],
25 encoding="utf-8",
26 errors="backslashreplace",
27 stdout=subprocess.PIPE,
28 stderr=subprocess.PIPE,
29 ) as p:
30 p.wait()
31 return p, p.stdout.read(), p.stderr.read()
32
33 def do_test(self, *args):
34 proc, stdout, stderr = self.run_test_in_subprocess(*args)

Callers 2

do_testMethod · 0.95
run_pythonMethod · 0.95

Calls 2

waitMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected