--strict is a deprecated alias to --strict-markers (#7530).
(pytester: Pytester)
| 102 | |
| 103 | |
| 104 | def test_strict_option_is_deprecated(pytester: Pytester) -> None: |
| 105 | """--strict is a deprecated alias to --strict-markers (#7530).""" |
| 106 | pytester.makepyfile( |
| 107 | """ |
| 108 | import pytest |
| 109 | |
| 110 | @pytest.mark.unknown |
| 111 | def test_foo(): pass |
| 112 | """ |
| 113 | ) |
| 114 | result = pytester.runpytest("--strict") |
| 115 | result.stdout.fnmatch_lines( |
| 116 | [ |
| 117 | "'unknown' not found in `markers` configuration option", |
| 118 | "*PytestRemovedIn8Warning: The --strict option is deprecated, use --strict-markers instead.", |
| 119 | ] |
| 120 | ) |
| 121 | |
| 122 | |
| 123 | def test_yield_fixture_is_deprecated() -> None: |
nothing calls this directly
no test coverage detected