Skip to content

Commit

Permalink
pdb: do not raise outcomes.Exit with quit in debug
Browse files Browse the repository at this point in the history
  • Loading branch information
blueyed committed Mar 21, 2019
1 parent 7764312 commit a36ed25
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/_pytest/debugging.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,15 @@ def do_continue(self, arg):
do_c = do_cont = do_continue

def set_quit(self):
"""Raise Exit outcome when quit command is used in pdb.
This is a bit of a hack - it would be better if BdbQuit
could be handled, but this would require to wrap the
whole pytest run, and adjust the report etc.
"""
super(_PdbWrapper, self).set_quit()
outcomes.exit("Quitting debugger")
if cls._recursive_debug == 0:
outcomes.exit("Quitting debugger")

def setup(self, f, tb):
"""Suspend on setup().
Expand Down

0 comments on commit a36ed25

Please sign in to comment.