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

Function test_fixturerequest_getmodulepath

testing/test_legacypath.py:90–95  ·  view source on GitHub ↗
(pytester: pytest.Pytester)

Source from the content-addressed store, hash-verified

88
89
90def test_fixturerequest_getmodulepath(pytester: pytest.Pytester) -> None:
91 modcol = pytester.getmodulecol("def test_somefunc(): pass")
92 (item,) = pytester.genitems([modcol])
93 req = pytest.FixtureRequest(item, _ispytest=True)
94 assert req.path == modcol.path
95 assert req.fspath == modcol.fspath # type: ignore[attr-defined]
96
97
98class TestFixtureRequestSessionScoped:

Callers

nothing calls this directly

Calls 2

getmodulecolMethod · 0.45
genitemsMethod · 0.45

Tested by

no test coverage detected