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

Method capturing

Lib/test/test_interpreters/utils.py:565–569  ·  view source on GitHub ↗
(self, script)

Source from the content-addressed store, hash-verified

563
564 @contextlib.contextmanager
565 def capturing(self, script):
566 wrapped, capturing = _captured_script(script, stdout=True, exc=True)
567 #_dump_script(wrapped)
568 with capturing:
569 yield wrapped, capturing.final(force=True)
570
571 @requires_test_modules
572 def run_from_capi(self, interpid, script, *, main=False):

Callers 2

run_from_capiMethod · 0.95
run_temp_from_capiMethod · 0.95

Calls 2

finalMethod · 0.80
_captured_scriptFunction · 0.70

Tested by

no test coverage detected