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

Method wrapper

Lib/test/test_subprocess.py:4151–4158  ·  view source on GitHub ↗
(*args, **kwargs)

Source from the content-addressed store, hash-verified

4149 p = subprocess.Popen(self.COMMAND)
4150
4151 def wrapper(*args, **kwargs):
4152 ret = real_func(*args, **kwargs)
4153 try:
4154 os.kill(p.pid, signal.SIGTERM)
4155 os.waitpid(p.pid, 0)
4156 except OSError:
4157 pass
4158 return ret
4159
4160 with mock.patch(patch_target, side_effect=wrapper) as m:
4161 status = p.wait(timeout=support.SHORT_TIMEOUT)

Callers

nothing calls this directly

Calls 1

killMethod · 0.45

Tested by

no test coverage detected