Remove funcargnames compatibility property

This commit is contained in:
Bruno Oliveira
2020-08-17 17:11:16 -03:00
parent c98525bd21
commit 98530184a5
6 changed files with 17 additions and 60 deletions

View File

@@ -53,7 +53,6 @@ from _pytest.config import ExitCode
from _pytest.config import hookimpl
from _pytest.config.argparsing import Parser
from _pytest.deprecated import FSCOLLECTOR_GETHOOKPROXY_ISINITPATH
from _pytest.deprecated import FUNCARGNAMES
from _pytest.fixtures import FuncFixtureInfo
from _pytest.main import Session
from _pytest.mark import MARK_GEN
@@ -906,12 +905,6 @@ class Metafunc:
self._calls = [] # type: List[CallSpec2]
self._arg2fixturedefs = fixtureinfo.name2fixturedefs
@property
def funcargnames(self) -> List[str]:
"""Alias attribute for ``fixturenames`` for pre-2.3 compatibility."""
warnings.warn(FUNCARGNAMES, stacklevel=2)
return self.fixturenames
def parametrize(
self,
argnames: Union[str, List[str], Tuple[str, ...]],
@@ -1568,12 +1561,6 @@ class Function(PyobjMixin, nodes.Item):
"""(compatonly) for code expecting pytest-2.2 style request objects."""
return self
@property
def funcargnames(self) -> List[str]:
"""Alias attribute for ``fixturenames`` for pre-2.3 compatibility."""
warnings.warn(FUNCARGNAMES, stacklevel=2)
return self.fixturenames
def runtest(self) -> None:
"""Execute the underlying test function."""
self.ihook.pytest_pyfunc_call(pyfuncitem=self)