MCPcopy Create free account
hub / github.com/microsoft/debugpy / test_breakpoint_in_package_main

Function test_breakpoint_in_package_main

tests/debugpy/test_breakpoints.py:233–247  ·  view source on GitHub ↗
(run)

Source from the content-addressed store, hash-verified

231
232@pytest.mark.parametrize("run", [runners.launch])
233def test_breakpoint_in_package_main(run):
234 testpkgs = test_data / "testpkgs"
235 main_py = testpkgs / "pkg1" / "__main__.py"
236
237 with debug.Session() as session:
238 session.expected_exit_code = 42
239 session.config["cwd"] = testpkgs.strpath
240
241 with run(session, targets.Module(name="pkg1")):
242 session.set_breakpoints(main_py, ["two"])
243
244 session.wait_for_stop(
245 "breakpoint", expected_frames=[some.dap.frame(main_py, line="two")]
246 )
247 session.request_continue()
248
249
250def test_add_and_remove_breakpoint(pyfile, target, run):

Callers

nothing calls this directly

Calls 4

set_breakpointsMethod · 0.80
wait_for_stopMethod · 0.80
request_continueMethod · 0.80
runFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…