(
self, pytester: Pytester, run_and_parse: RunAndParse, xunit_family: str
)
| 168 | |
| 169 | @parametrize_families |
| 170 | def test_summing_simple_with_errors( |
| 171 | self, pytester: Pytester, run_and_parse: RunAndParse, xunit_family: str |
| 172 | ) -> None: |
| 173 | pytester.makepyfile( |
| 174 | """ |
| 175 | import pytest |
| 176 | @pytest.fixture |
| 177 | def fixture(): |
| 178 | raise Exception() |
| 179 | def test_pass(): |
| 180 | pass |
| 181 | def test_fail(): |
| 182 | assert 0 |
| 183 | def test_error(fixture): |
| 184 | pass |
| 185 | @pytest.mark.xfail |
| 186 | def test_xfail(): |
| 187 | assert False |
| 188 | @pytest.mark.xfail(strict=True) |
| 189 | def test_xpass(): |
| 190 | assert True |
| 191 | """ |
| 192 | ) |
| 193 | result, dom = run_and_parse(family=xunit_family) |
| 194 | assert result.ret |
| 195 | node = dom.find_first_by_tag("testsuite") |
| 196 | node.assert_attr(name="pytest", errors=1, failures=2, skipped=1, tests=5) |
| 197 | |
| 198 | @parametrize_families |
| 199 | def test_hostname_in_xml( |
nothing calls this directly
no test coverage detected