MCPcopy Create free account
hub / github.com/pytest-dev/pytest / test_escaped_parametrized_names_xml

Function test_escaped_parametrized_names_xml

testing/test_junitxml.py:1127–1141  ·  view source on GitHub ↗
(
    pytester: Pytester, run_and_parse: RunAndParse
)

Source from the content-addressed store, hash-verified

1125
1126
1127def test_escaped_parametrized_names_xml(
1128 pytester: Pytester, run_and_parse: RunAndParse
1129) -> None:
1130 pytester.makepyfile(
1131 """\
1132 import pytest
1133 @pytest.mark.parametrize('char', ["\\x00"])
1134 def test_func(char):
1135 assert char
1136 """
1137 )
1138 result, dom = run_and_parse()
1139 assert result.ret == 0
1140 node = dom.find_first_by_tag("testcase")
1141 node.assert_attr(name="test_func[\\x00]")
1142
1143
1144def test_double_colon_split_function_issue469(

Callers

nothing calls this directly

Calls 4

run_and_parseFunction · 0.85
find_first_by_tagMethod · 0.80
assert_attrMethod · 0.80
makepyfileMethod · 0.45

Tested by

no test coverage detected