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

Method __init__

src/_pytest/fixtures.py:441–451  ·  view source on GitHub ↗
(self, pyfuncitem, *, _ispytest: bool = False)

Source from the content-addressed store, hash-verified

439 """
440
441 def __init__(self, pyfuncitem, *, _ispytest: bool = False) -> None:
442 check_ispytest(_ispytest)
443 self._pyfuncitem = pyfuncitem
444 #: Fixture for which this request is being performed.
445 self.fixturename: Optional[str] = None
446 self._scope = Scope.Function
447 self._fixture_defs: Dict[str, FixtureDef[Any]] = {}
448 fixtureinfo: FuncFixtureInfo = pyfuncitem._fixtureinfo
449 self._arg2fixturedefs = fixtureinfo.name2fixturedefs.copy()
450 self._arg2index: Dict[str, int] = {}
451 self._fixturemanager: FixtureManager = pyfuncitem.session._fixturemanager
452
453 @property
454 def scope(self) -> "_ScopeName":

Callers

nothing calls this directly

Calls 1

check_ispytestFunction · 0.90

Tested by

no test coverage detected