MCPcopy Create free account
hub / github.com/python/cpython / test_ignore_count_on_disabled_bp

Method test_ignore_count_on_disabled_bp

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

Source from the content-addressed store, hash-verified

914 tracer.runcall(tfunc_import)
915
916 def test_ignore_count_on_disabled_bp(self):
917 code = """
918 def func():
919 lno = 3
920
921 def main():
922 for i in range(3):
923 func()
924 """
925 modules = { TEST_MODULE: code }
926 with create_modules(modules):
927 self.expect_set = [
928 ('line', 2, 'tfunc_import'),
929 break_in_func('func', TEST_MODULE_FNAME),
930 ('None', 2, 'tfunc_import'),
931 break_in_func('func', TEST_MODULE_FNAME),
932 ('None', 2, 'tfunc_import'), ('ignore', (1, )),
933 ('None', 2, 'tfunc_import'), ('disable', (1, )),
934 ('None', 2, 'tfunc_import'), ('continue', ),
935 ('line', 3, 'func', ({2:1}, [])), ('enable', (1, )),
936 ('None', 3, 'func'), ('continue', ),
937 ('line', 3, 'func', ({2:2}, [])), ('continue', ),
938 ('line', 3, 'func', ({1:2}, [])), ('quit', ),
939 ]
940 with TracerRun(self) as tracer:
941 tracer.runcall(tfunc_import)
942
943 def test_clear_two_bp_on_same_line(self):
944 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