summaryrefslogtreecommitdiff
path: root/_pytest
diff options
context:
space:
mode:
authorRonny Pfannschmidt <opensource@ronnypfannschmidt.de>2018-03-16 15:56:45 +0100
committerRonny Pfannschmidt <opensource@ronnypfannschmidt.de>2018-03-29 17:52:01 +0200
commite8feee0612246d4f3414530388c9aee6dd0f563c (patch)
tree484affed414cca86545798c888c14718477e8562 /_pytest
parentf1a1695aaabf554fea21382b7edc0ee79e59b3d5 (diff)
downloadpytest-e8feee0612246d4f3414530388c9aee6dd0f563c.tar.gz
fix up the mark evaluator validity check
Diffstat (limited to '_pytest')
-rw-r--r--_pytest/mark/evaluate.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/_pytest/mark/evaluate.py b/_pytest/mark/evaluate.py
index 1aef138b1..19eff8e00 100644
--- a/_pytest/mark/evaluate.py
+++ b/_pytest/mark/evaluate.py
@@ -27,7 +27,8 @@ class MarkEvaluator(object):
self._mark_name = name
def __bool__(self):
- return bool(self._marks)
+ # dont cache here to prevent staleness
+ return bool(self._get_marks())
__nonzero__ = __bool__
def wasvalid(self):