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

Method test_disabled_temporary_bp

Lib/test/test_bdb.py:828–854  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

826 tracer.runcall(tfunc_import)
827
828 def test_disabled_temporary_bp(self):
829 code = """
830 def func():
831 lno = 3
832
833 def main():
834 for i in range(3):
835 func()
836 """
837 modules = { TEST_MODULE: code }
838 with create_modules(modules):
839 self.expect_set = [
840 ('line', 2, 'tfunc_import'),
841 break_in_func('func', TEST_MODULE_FNAME),
842 ('None', 2, 'tfunc_import'),
843 break_in_func('func', TEST_MODULE_FNAME, True),
844 ('None', 2, 'tfunc_import'), ('disable', (2, )),
845 ('None', 2, 'tfunc_import'), ('continue', ),
846 ('line', 3, 'func', ({1:1}, [])), ('enable', (2, )),
847 ('None', 3, 'func'), ('disable', (1, )),
848 ('None', 3, 'func'), ('continue', ),
849 ('line', 3, 'func', ({2:1}, [2])), ('enable', (1, )),
850 ('None', 3, 'func'), ('continue', ),
851 ('line', 3, 'func', ({1:2}, [])), ('quit', ),
852 ]
853 with TracerRun(self) as tracer:
854 tracer.runcall(tfunc_import)
855
856 def test_bp_condition(self):
857 code = """

Callers

nothing calls this directly

Calls 4

break_in_funcFunction · 0.85
TracerRunClass · 0.85
create_modulesFunction · 0.70
runcallMethod · 0.45

Tested by

no test coverage detected