From 8b4c59e606285d76011934e61eb7b110262f37ff Mon Sep 17 00:00:00 2001 From: Anthony Sottile Date: Thu, 21 Jun 2018 13:24:16 -0700 Subject: [PATCH] Silence usage of `reduce` warning in python 2 --- changelog/3609.trivial.rst | 1 + src/_pytest/mark/structures.py | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 changelog/3609.trivial.rst diff --git a/changelog/3609.trivial.rst b/changelog/3609.trivial.rst new file mode 100644 index 00000000000..96e720d9291 --- /dev/null +++ b/changelog/3609.trivial.rst @@ -0,0 +1 @@ +Silence usage of ``reduce`` warning in python 2 diff --git a/src/_pytest/mark/structures.py b/src/_pytest/mark/structures.py index 1a2bd73de56..ceacc5c6ba4 100644 --- a/src/_pytest/mark/structures.py +++ b/src/_pytest/mark/structures.py @@ -1,13 +1,14 @@ import inspect import warnings from collections import namedtuple +from functools import reduce from operator import attrgetter import attr from ..deprecated import MARK_PARAMETERSET_UNPACKING, MARK_INFO_ATTRIBUTE from ..compat import NOTSET, getfslineno, MappingMixin -from six.moves import map, reduce +from six.moves import map EMPTY_PARAMETERSET_OPTION = "empty_parameter_set_mark"