Issue 5115.
(pytester: Pytester, recwarn)
| 636 | |
| 637 | |
| 638 | def test_pytest_configure_warning(pytester: Pytester, recwarn) -> None: |
| 639 | """Issue 5115.""" |
| 640 | pytester.makeconftest( |
| 641 | """ |
| 642 | def pytest_configure(): |
| 643 | import warnings |
| 644 | |
| 645 | warnings.warn("from pytest_configure") |
| 646 | """ |
| 647 | ) |
| 648 | |
| 649 | result = pytester.runpytest() |
| 650 | assert result.ret == 5 |
| 651 | assert "INTERNALERROR" not in result.stderr.str() |
| 652 | warning = recwarn.pop() |
| 653 | assert str(warning.message) == "from pytest_configure" |
| 654 | |
| 655 | |
| 656 | class TestStackLevel: |
nothing calls this directly
no test coverage detected