Skip to content

Commit c9c4a3d

Browse files
committed
TEMP: re-add test_pdb_interaction before failing test_pdb_unittest_postmortem
1 parent 899df7c commit c9c4a3d

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

testing/test_pdb.py

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,29 @@ def test_func():
147147
assert rep.failed
148148
assert len(pdblist) == 1
149149

150+
# TEMP/DEBUG
151+
def test_pdb_interaction(self, testdir):
152+
p1 = testdir.makepyfile(
153+
"""
154+
def test_1():
155+
i = 0
156+
assert i == 1
157+
158+
def test_not_called_due_to_quit():
159+
pass
160+
"""
161+
)
162+
child = testdir.spawn_pytest("--pdb %s" % p1)
163+
child.expect(".*def test_1")
164+
child.expect(".*i = 0")
165+
child.expect("Pdb")
166+
child.sendeof()
167+
rest = child.read().decode("utf8")
168+
assert "= 1 failed in" in rest
169+
assert "def test_1" not in rest
170+
assert "Exit: Quitting debugger" in rest
171+
self.flush(child)
172+
150173
@staticmethod
151174
def flush(child):
152175
if platform.system() == "Darwin":

0 commit comments

Comments
 (0)