(
self, pytester: Pytester, run_and_parse: RunAndParse, xunit_family: str
)
| 614 | |
| 615 | @parametrize_families |
| 616 | def test_junit_prefixing( |
| 617 | self, pytester: Pytester, run_and_parse: RunAndParse, xunit_family: str |
| 618 | ) -> None: |
| 619 | pytester.makepyfile( |
| 620 | """ |
| 621 | def test_func(): |
| 622 | assert 0 |
| 623 | class TestHello(object): |
| 624 | def test_hello(self): |
| 625 | pass |
| 626 | """ |
| 627 | ) |
| 628 | result, dom = run_and_parse("--junitprefix=xyz", family=xunit_family) |
| 629 | assert result.ret |
| 630 | node = dom.find_first_by_tag("testsuite") |
| 631 | node.assert_attr(failures=1, tests=2) |
| 632 | tnode = node.find_first_by_tag("testcase") |
| 633 | tnode.assert_attr(classname="xyz.test_junit_prefixing", name="test_func") |
| 634 | tnode = node.find_nth_by_tag("testcase", 1) |
| 635 | tnode.assert_attr( |
| 636 | classname="xyz.test_junit_prefixing.TestHello", name="test_hello" |
| 637 | ) |
| 638 | |
| 639 | @parametrize_families |
| 640 | def test_xfailure_function( |
nothing calls this directly
no test coverage detected