summaryrefslogtreecommitdiff
path: root/src/_pytest/debugging.py
diff options
context:
space:
mode:
authorDaniel Hahler <git@thequod.de>2019-04-29 05:45:21 +0200
committerDaniel Hahler <git@thequod.de>2019-04-29 05:46:21 +0200
commit02053bf556c9580f77c3dd8f5530e31efed6f0ee (patch)
treeec852c01fc48fc5fe8002657b9a65c1b3584450f /src/_pytest/debugging.py
parentac7ee40aafa675fedf1f9300306d862520f40295 (diff)
downloadpytest-02053bf556c9580f77c3dd8f5530e31efed6f0ee.tar.gz
debugging: rename internal wrapper for pdb.Pdb
This is useful/clearer in case of errors / tracebacks - i.e. you see clearly that it is coming from pytest.
Diffstat (limited to 'src/_pytest/debugging.py')
-rw-r--r--src/_pytest/debugging.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/_pytest/debugging.py b/src/_pytest/debugging.py
index d8a3adc08..7138fd2e1 100644
--- a/src/_pytest/debugging.py
+++ b/src/_pytest/debugging.py
@@ -143,18 +143,18 @@ class pytestPDB(object):
else:
tw.sep(">", "PDB set_trace")
- class _PdbWrapper(cls._pdb_cls, object):
+ class PytestPdbWrapper(cls._pdb_cls, object):
_pytest_capman = capman
_continued = False
def do_debug(self, arg):
cls._recursive_debug += 1
- ret = super(_PdbWrapper, self).do_debug(arg)
+ ret = super(PytestPdbWrapper, self).do_debug(arg)
cls._recursive_debug -= 1
return ret
def do_continue(self, arg):
- ret = super(_PdbWrapper, self).do_continue(arg)
+ ret = super(PytestPdbWrapper, self).do_continue(arg)
if cls._recursive_debug == 0:
tw = _pytest.config.create_terminal_writer(cls._config)
tw.line()
@@ -188,7 +188,7 @@ class pytestPDB(object):
could be handled, but this would require to wrap the
whole pytest run, and adjust the report etc.
"""
- super(_PdbWrapper, self).set_quit()
+ super(PytestPdbWrapper, self).set_quit()
if cls._recursive_debug == 0:
outcomes.exit("Quitting debugger")
@@ -198,7 +198,7 @@ class pytestPDB(object):
Needed after do_continue resumed, and entering another
breakpoint again.
"""
- ret = super(_PdbWrapper, self).setup(f, tb)
+ ret = super(PytestPdbWrapper, self).setup(f, tb)
if not ret and self._continued:
# pdb.setup() returns True if the command wants to exit
# from the interaction: do not suspend capturing then.
@@ -206,7 +206,7 @@ class pytestPDB(object):
self._pytest_capman.suspend_global_capture(in_=True)
return ret
- _pdb = _PdbWrapper(**kwargs)
+ _pdb = PytestPdbWrapper(**kwargs)
cls._pluginmanager.hook.pytest_enter_pdb(config=cls._config, pdb=_pdb)
else:
_pdb = cls._pdb_cls(**kwargs)