From a9c5d318061055c89a0e3793aa474b00cfebf6e5 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Sat, 1 Feb 2020 06:27:41 +0100 Subject: [PATCH] PyCollector._genfunctions: use already created fixtureinfo (#6636) `Function` creates a `_fixtureinfo` already: https://github.com/pytest-dev/pytest/blob/fed535694/src/_pytest/python.py#L1392-L1395 --- src/_pytest/python.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/_pytest/python.py b/src/_pytest/python.py index 1b94aaf00..65ef1272b 100644 --- a/src/_pytest/python.py +++ b/src/_pytest/python.py @@ -390,7 +390,7 @@ class PyCollector(PyobjMixin, nodes.Collector): fm = self.session._fixturemanager definition = FunctionDefinition(name=name, parent=self, callobj=funcobj) - fixtureinfo = fm.getfixtureinfo(definition, funcobj, cls) + fixtureinfo = definition._fixtureinfo metafunc = Metafunc( definition, fixtureinfo, self.config, cls=cls, module=module