summaryrefslogtreecommitdiff
path: root/repoze/bfg/tests
diff options
context:
space:
mode:
Diffstat (limited to 'repoze/bfg/tests')
-rw-r--r--repoze/bfg/tests/test_zcml.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/repoze/bfg/tests/test_zcml.py b/repoze/bfg/tests/test_zcml.py
index 4d29c8373..2d9d59b64 100644
--- a/repoze/bfg/tests/test_zcml.py
+++ b/repoze/bfg/tests/test_zcml.py
@@ -69,6 +69,15 @@ class TestViewDirective(unittest.TestCase):
self.assertEqual(result, 'OK')
self.failIf(hasattr(view, '__call_permissive__'))
+ def test_request_type_asnoninterfacestring(self):
+ from repoze.bfg.exceptions import ConfigurationError
+ context = DummyContext('notaninterface')
+ view = lambda *arg: 'OK'
+ self.assertRaises(ConfigurationError,
+ self._callFUT,
+ context, 'repoze.view', IDummy, view=view,
+ request_type='whatever')
+
def test_with_dotted_renderer(self):
from repoze.bfg.threadlocal import get_current_registry
from repoze.bfg.interfaces import IView