Skip to content

Commit 00bd710

Browse files
add docstrings for nodemarkers
1 parent f357d69 commit 00bd710

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

_pytest/mark/structures.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,14 @@ def __repr__(self):
369369

370370
@attr.s(cmp=False, hash=False)
371371
class NodeMarkers(object):
372+
"""
373+
internal strucutre for storing marks belongong to a node
374+
375+
..warning::
376+
377+
unstable api
378+
379+
"""
372380
own_markers = attr.ib(default=attr.Factory(list))
373381

374382
def update(self, add_markers):

_pytest/nodes.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,10 @@ def add_marker(self, marker):
183183
self._markers.update([marker])
184184

185185
def find_markers(self, name):
186-
"""find all marks with the given name on the node and its parents"""
186+
"""find all marks with the given name on the node and its parents
187+
188+
:param str name: name of the marker
189+
"""
187190
for node in reversed(self.listchain()):
188191
for mark in node._markers.find(name):
189192
yield mark

0 commit comments

Comments
 (0)