From dfd219842b7ddb68fc5ff29d2c7bd55ac56b5e29 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Thu, 23 Jun 2011 15:46:19 -0400 Subject: coverage --- pyramid/config.py | 2 +- pyramid/tests/test_config.py | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pyramid/config.py b/pyramid/config.py index 418e393f4..3681e48ee 100644 --- a/pyramid/config.py +++ b/pyramid/config.py @@ -2699,7 +2699,7 @@ def _make_predicates(xhr=None, request_method=None, path_info=None, # if this happens the predicate is probably a classmethod if hasattr(predicate, '__func__'): predicate.__func__.__text__ = text - else: # 2.5 doesn't have __func__ + else: # # pragma: no cover ; 2.5 doesn't have __func__ predicate.im_func.__text__ = text predicates.append(predicate) # using hash() here rather than id() is intentional: we diff --git a/pyramid/tests/test_config.py b/pyramid/tests/test_config.py index 5c102132c..41811782a 100644 --- a/pyramid/tests/test_config.py +++ b/pyramid/tests/test_config.py @@ -5218,14 +5218,12 @@ class DummyCustomPredicate(object): def __init__(self): self.__text__ = 'custom predicate' - def classmethod_predicate(*args): - pass + def classmethod_predicate(*args): pass classmethod_predicate.__text__ = 'classmethod predicate' classmethod_predicate = classmethod(classmethod_predicate) @classmethod - def classmethod_predicate_no_text(*args): - pass + def classmethod_predicate_no_text(*args): pass # pragma: no cover def dummy_view(request): return 'OK' -- cgit v1.2.3