MCPcopy Create free account
hub / github.com/pytest-dev/pytest / runpdb_and_get_report

Function runpdb_and_get_report

testing/test_debugging.py:31–36  ·  view source on GitHub ↗
(pytester: Pytester, source: str)

Source from the content-addressed store, hash-verified

29
30
31def runpdb_and_get_report(pytester: Pytester, source: str):
32 p = pytester.makepyfile(source)
33 result = pytester.runpytest_inprocess("--pdb", p)
34 reports = result.reprec.getreports("pytest_runtest_logreport") # type: ignore[attr-defined]
35 assert len(reports) == 3, reports # setup/call/teardown
36 return reports[1]
37
38
39@pytest.fixture

Callers 5

test_pdb_on_failMethod · 0.85
test_pdb_on_xfailMethod · 0.85
test_pdb_on_skipMethod · 0.85
test_pdb_on_BdbQuitMethod · 0.85

Calls 3

makepyfileMethod · 0.45
runpytest_inprocessMethod · 0.45
getreportsMethod · 0.45

Tested by

no test coverage detected