diff --git a/changelog/5634.bugfix.rst b/changelog/5634.bugfix.rst index f4699919b..a2a282f93 100644 --- a/changelog/5634.bugfix.rst +++ b/changelog/5634.bugfix.rst @@ -1 +1,2 @@ -``pytest.exit`` and ``bdb.BdbQuit`` are now correctly handled in ``unittest`` cases. +``pytest.exit`` is now correctly handled in ``unittest`` cases. +This makes ``unittest`` cases handle ``quit`` from pytest's pdb correctly. diff --git a/testing/test_unittest.py b/testing/test_unittest.py index 153b76a89..ec5f92e18 100644 --- a/testing/test_unittest.py +++ b/testing/test_unittest.py @@ -1085,4 +1085,4 @@ def test_exit_outcome(testdir): """ ) result = testdir.runpytest() - result.stdout.fnmatch_lines("*Exit: pytest_exit called*") + result.stdout.fnmatch_lines(["*Exit: pytest_exit called*", "*= no tests ran in *"])