summaryrefslogtreecommitdiff
path: root/repoze/bfg/tests
diff options
context:
space:
mode:
Diffstat (limited to 'repoze/bfg/tests')
-rw-r--r--repoze/bfg/tests/test_router.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/repoze/bfg/tests/test_router.py b/repoze/bfg/tests/test_router.py
index 1b76c0b7e..29ebf61d5 100644
--- a/repoze/bfg/tests/test_router.py
+++ b/repoze/bfg/tests/test_router.py
@@ -138,6 +138,11 @@ class RouterTests(unittest.TestCase):
self.assertEqual(len(logger.messages), 1)
self.failUnless('which does not have a "forbidden" method'
in logger.messages[0])
+ class DummyRequest:
+ environ = {}
+ req = DummyRequest()
+ resp = router.forbidden_resp_factory(None, req)
+ self.assertEqual(resp.status, '401 Unauthorized')
def test_secpol_with_iunauthorized_appfactory(self):
from repoze.bfg.interfaces import IUnauthorizedAppFactory