summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorJonathan Lange <jml@mumak.net>2012-04-10 14:12:20 +0100
committerJonathan Lange <jml@mumak.net>2012-04-10 14:12:20 +0100
commitbd5107a642a7b704661e492566e588e944669a25 (patch)
tree13b31d96ed815bc17378f57716bf3aef02b1bf53 /python
parent6f3bfe4a750ed5c34a1e61705593d935c0cff38d (diff)
downloadsubunit-git-bd5107a642a7b704661e492566e588e944669a25.tar.gz
A layer of abstraction that can help us.
Diffstat (limited to 'python')
-rw-r--r--python/subunit/test_results.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/python/subunit/test_results.py b/python/subunit/test_results.py
index 7acd5ea..92e0310 100644
--- a/python/subunit/test_results.py
+++ b/python/subunit/test_results.py
@@ -292,7 +292,7 @@ class _PredicateFilter(TestResultDecorator):
super(_PredicateFilter, self).__init__(result)
self.decorated = TimeCollapsingDecorator(
TagCollapsingDecorator(self.decorated))
- self.filter_predicate = predicate
+ self._predicate = predicate
# The current test (for filtering tags)
self._current_test = None
# Has the current test been filtered (for outputting test tags)
@@ -300,6 +300,9 @@ class _PredicateFilter(TestResultDecorator):
# Calls to this result that we don't know whether to forward on yet.
self._buffered_calls = []
+ def filter_predicate(self, test, outcome, error, details):
+ return self._predicate(test, outcome, error, details)
+
def addError(self, test, err=None, details=None):
if (self.filter_predicate(test, 'error', err, details)):
self._buffered_calls.append(