(self, pytester: Pytester, params)
| 899 | "params", ["\"hasattr(sys, 'platform')\"", 'True, reason="invalid platform"'] |
| 900 | ) |
| 901 | def test_skipif_reporting(self, pytester: Pytester, params) -> None: |
| 902 | p = pytester.makepyfile( |
| 903 | test_foo=""" |
| 904 | import pytest |
| 905 | @pytest.mark.skipif(%(params)s) |
| 906 | def test_that(): |
| 907 | assert 0 |
| 908 | """ |
| 909 | % dict(params=params) |
| 910 | ) |
| 911 | result = pytester.runpytest(p, "-s", "-rs") |
| 912 | result.stdout.fnmatch_lines(["*SKIP*1*test_foo.py*platform*", "*1 skipped*"]) |
| 913 | assert result.ret == 0 |
| 914 | |
| 915 | def test_skipif_using_platform(self, pytester: Pytester) -> None: |
| 916 | item = pytester.getitem( |
nothing calls this directly
no test coverage detected