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

Function test_pytest_param_id_requires_string

testing/test_mark.py:1104–1108  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1102
1103
1104def test_pytest_param_id_requires_string() -> None:
1105 with pytest.raises(TypeError) as excinfo:
1106 pytest.param(id=True) # type: ignore[arg-type]
1107 (msg,) = excinfo.value.args
1108 assert msg == "Expected id to be a string, got <class 'bool'>: True"
1109
1110
1111@pytest.mark.parametrize("s", (None, "hello world"))

Callers

nothing calls this directly

Calls 1

paramMethod · 0.80

Tested by

no test coverage detected