MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / debug

Function debug

tools/python-3.11.9-amd64/Lib/doctest.py:2677–2686  ·  view source on GitHub ↗

Debug a single doctest docstring. Provide the module (or dotted name of the module) containing the test to be debugged and the name (within the module) of the object with the docstring with tests to be debugged.

(module, name, pm=False)

Source from the content-addressed store, hash-verified

2675 pdb.Pdb(nosigint=True).run("exec(%r)" % src, globs, globs)
2676
2677def debug(module, name, pm=False):
2678 """Debug a single doctest docstring.
2679
2680 Provide the module (or dotted name of the module) containing the
2681 test to be debugged and the name (within the module) of the object
2682 with the docstring with tests to be debugged.
2683 """
2684 module = _normalize_module(module)
2685 testsrc = testsource(module, name)
2686 debug_script(testsrc, pm, module.__dict__)
2687
2688######################################################################
2689## 9. Example Usage

Callers

nothing calls this directly

Calls 3

_normalize_moduleFunction · 0.85
testsourceFunction · 0.85
debug_scriptFunction · 0.85

Tested by

no test coverage detected