diff --git a/_pytest/nodes.py b/_pytest/nodes.py index 9b41664c1..e836cd4d6 100644 --- a/_pytest/nodes.py +++ b/_pytest/nodes.py @@ -1,12 +1,14 @@ from __future__ import absolute_import, division, print_function from collections import MutableMapping as MappingMixin - import os import six import py +import attr + import _pytest + SEP = "/" tracebackcutdir = py.path.local(_pytest.__file__).dirpath() @@ -48,9 +50,9 @@ def ischildnode(baseid, nodeid): return node_parts[:len(base_parts)] == base_parts +@attr.s class _CompatProperty(object): - def __init__(self, name): - self.name = name + name = attr.ib() def __get__(self, obj, owner): if obj is None: