(self, pytester: Pytester)
| 785 | assert class="st">"= 1 passed in" in rest |
| 786 | |
| 787 | def test_pdb_used_outside_test(self, pytester: Pytester) -> None: |
| 788 | p1 = pytester.makepyfile( |
| 789 | class="st">""" |
| 790 | import pytest |
| 791 | pytest.set_trace() |
| 792 | x = 5 |
| 793 | class="st">""" |
| 794 | ) |
| 795 | if sys.version_info[:2] >= (3, 13): |
| 796 | break_line = class="st">"pytest.set_trace()" |
| 797 | else: |
| 798 | break_line = class="st">"x = 5" |
| 799 | child = pytester.spawn(fclass="st">"{sys.executable} {p1}") |
| 800 | child.expect_exact(break_line) |
| 801 | child.expect_exact(class="st">"Pdb") |
| 802 | child.sendeof() |
| 803 | self.flush(child) |
| 804 | |
| 805 | def test_pdb_used_in_generate_tests(self, pytester: Pytester) -> None: |
| 806 | p1 = pytester.makepyfile( |
nothing calls this directly
no test coverage detected