From 547070e2d83617988ce07f2de6240f3ba3705d9c Mon Sep 17 00:00:00 2001 From: Alan Velasco Date: Tue, 30 Jan 2018 16:20:43 -0600 Subject: [PATCH 1/2] Switch `for_parameterize` to `for_parametrize` --- _pytest/mark.py | 2 +- _pytest/python.py | 4 ++-- changelog/3166.trivial | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 changelog/3166.trivial diff --git a/_pytest/mark.py b/_pytest/mark.py index 3f1f01b1a..f2d31761a 100644 --- a/_pytest/mark.py +++ b/_pytest/mark.py @@ -70,7 +70,7 @@ class ParameterSet(namedtuple('ParameterSet', 'values, marks, id')): return cls(argval, marks=newmarks, id=None) @classmethod - def _for_parameterize(cls, argnames, argvalues, function): + def _for_parametrize(cls, argnames, argvalues, function, config): if not isinstance(argnames, (tuple, list)): argnames = [x.strip() for x in argnames.split(",") if x.strip()] force_tuple = len(argnames) == 1 diff --git a/_pytest/python.py b/_pytest/python.py index 3940028fa..a4c233076 100644 --- a/_pytest/python.py +++ b/_pytest/python.py @@ -785,8 +785,8 @@ class Metafunc(fixtures.FuncargnamesCompatAttr): from _pytest.fixtures import scope2index from _pytest.mark import ParameterSet from py.io import saferepr - argnames, parameters = ParameterSet._for_parameterize( - argnames, argvalues, self.function) + argnames, parameters = ParameterSet._for_parametrize( + argnames, argvalues, self.function, self.config) del argvalues if scope is None: diff --git a/changelog/3166.trivial b/changelog/3166.trivial new file mode 100644 index 000000000..0f6ca240e --- /dev/null +++ b/changelog/3166.trivial @@ -0,0 +1 @@ +Change the naming of ``_for_parameterize()`` to ``_for_parametrize()`` in order to comply with the naming convention. \ No newline at end of file From ef7df8f167cdcf774bd3688f4df98ee10b80766d Mon Sep 17 00:00:00 2001 From: Bruno Oliveira Date: Tue, 30 Jan 2018 21:40:14 -0200 Subject: [PATCH 2/2] Small update to CHANGELOG --- changelog/3166.trivial | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog/3166.trivial b/changelog/3166.trivial index 0f6ca240e..ce92840cb 100644 --- a/changelog/3166.trivial +++ b/changelog/3166.trivial @@ -1 +1 @@ -Change the naming of ``_for_parameterize()`` to ``_for_parametrize()`` in order to comply with the naming convention. \ No newline at end of file +Rename ``ParameterSet._for_parameterize()`` to ``_for_parametrize()`` in order to comply with the naming convention.