MCPcopy
hub / github.com/pytest-dev/pytest / test_request_getmodulepath

Method test_request_getmodulepath

testing/python/fixtures.py:1148–1153  ·  view source on GitHub ↗
(self, pytester: Pytester)

Source from the content-addressed store, hash-verified

1146 )
1147
1148 def test_request_getmodulepath(self, pytester: Pytester) -> None:
1149 modcol = pytester.getmodulecol("def test_somefunc(): pass")
1150 (item,) = pytester.genitems([modcol])
1151 assert isinstance(item, Function)
1152 req = TopRequest(item, _ispytest=True)
1153 assert req.path == modcol.path
1154
1155 def test_request_fixturenames(self, pytester: Pytester) -> None:
1156 pytester.makepyfile(

Callers

nothing calls this directly

Calls 3

TopRequestClass · 0.90
getmodulecolMethod · 0.45
genitemsMethod · 0.45

Tested by

no test coverage detected