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

Method test_breakpoint

Lib/test/test_pdb.py:4176–4189  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

4174 self.assertIn("['--bar', 'foo']", stdout)
4175
4176 def test_breakpoint(self):
4177 script = """
4178 if __name__ == '__main__':
4179 pass
4180 print("SUCCESS")
4181 pass
4182 """
4183 commands = """
4184 b 3
4185 quit
4186 """
4187 stdout, stderr = self.run_pdb_module(script, commands)
4188 self.assertTrue(any("Breakpoint 1 at" in l for l in stdout.splitlines()), stdout)
4189 self.assertTrue(all("SUCCESS" not in l for l in stdout.splitlines()), stdout)
4190
4191 def test_run_pdb_with_pdb(self):
4192 commands = """

Callers

nothing calls this directly

Calls 4

run_pdb_moduleMethod · 0.95
assertTrueMethod · 0.80
anyFunction · 0.50
splitlinesMethod · 0.45

Tested by

no test coverage detected