def test_postmortem_noargs(): def fn(): try: a = 1 1/0 except ZeroDivisionError: pdb.post_mortem(Pdb=PdbTest) check(fn, """ [NUM] > .*fn() -> 1/0 # c """)