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

Method _getinstance

src/_pytest/python.py:1684–1689  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1682 return self._instance
1683
1684 def _getinstance(self):
1685 if isinstance(self.parent, Class):
1686 # Each Function gets a fresh class instance.
1687 return self.parent.newinstance()
1688 else:
1689 return None
1690
1691 def _getobj(self):
1692 instance = self.instance

Callers 1

instanceMethod · 0.95

Calls 1

newinstanceMethod · 0.45

Tested by

no test coverage detected