summaryrefslogtreecommitdiff
path: root/pyramid/tests/test_config.py
diff options
context:
space:
mode:
Diffstat (limited to 'pyramid/tests/test_config.py')
-rw-r--r--pyramid/tests/test_config.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/pyramid/tests/test_config.py b/pyramid/tests/test_config.py
index 4620c05aa..ec04f177b 100644
--- a/pyramid/tests/test_config.py
+++ b/pyramid/tests/test_config.py
@@ -763,6 +763,14 @@ pyramid.tests.test_config.dummy_include2""",
config.add_tween, 'pyramid.tests.test_config.dummy_tween_factory',
over=INGRESS)
+ def test_add_tween_over_ingress_iterable(self):
+ from pyramid.exceptions import ConfigurationError
+ from pyramid.tweens import INGRESS
+ config = self._makeOne()
+ self.assertRaises(ConfigurationError,
+ config.add_tween, 'pyramid.tests.test_config.dummy_tween_factory',
+ over=('a', INGRESS))
+
def test_add_tween_under_main(self):
from pyramid.exceptions import ConfigurationError
from pyramid.tweens import MAIN
@@ -771,6 +779,14 @@ pyramid.tests.test_config.dummy_include2""",
config.add_tween, 'pyramid.tests.test_config.dummy_tween_factory',
under=MAIN)
+ def test_add_tween_under_main_iterable(self):
+ from pyramid.exceptions import ConfigurationError
+ from pyramid.tweens import MAIN
+ config = self._makeOne()
+ self.assertRaises(ConfigurationError,
+ config.add_tween, 'pyramid.tests.test_config.dummy_tween_factory',
+ under=('a', MAIN))
+
def test_add_subscriber_defaults(self):
from zope.interface import implements
from zope.interface import Interface