From 19a57525d59ec88c1f121499bfdcc56d05a525a5 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Tue, 23 Aug 2011 03:19:16 -0400 Subject: give the connect action a discriminator too --- pyramid/config/routes.py | 2 +- pyramid/tests/test_config/test_init.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pyramid/config/routes.py b/pyramid/config/routes.py index 0360bad9d..6de9b6e59 100644 --- a/pyramid/config/routes.py +++ b/pyramid/config/routes.py @@ -375,7 +375,7 @@ class RoutesConfiguratorMixin(object): # We have to connect routes in the order they were provided; # we can't use a phase to do that, because when the actions are # sorted, actions in the same phase lose relative ordering - self.action(None, register_connect) + self.action(('route-connect', name), register_connect) # But IRouteRequest interfaces must be registered before we begin to # process view registrations (in phase 3) diff --git a/pyramid/tests/test_config/test_init.py b/pyramid/tests/test_config/test_init.py index fb355a0af..ea4bdcac3 100644 --- a/pyramid/tests/test_config/test_init.py +++ b/pyramid/tests/test_config/test_init.py @@ -3716,11 +3716,13 @@ class TestConfiguratorDeprecatedFeatures(unittest.TestCase): try: config.commit() except ConfigurationConflictError, why: - c1, c2, c3, c4 = self._conflictFunctions(why) + c1, c2, c3, c4, c5, c6 = self._conflictFunctions(why) self.assertEqual(c1, 'test_conflict_route_with_view') self.assertEqual(c2, 'test_conflict_route_with_view') self.assertEqual(c3, 'test_conflict_route_with_view') self.assertEqual(c4, 'test_conflict_route_with_view') + self.assertEqual(c5, 'test_conflict_route_with_view') + self.assertEqual(c6, 'test_conflict_route_with_view') else: # pragma: no cover raise AssertionError -- cgit v1.2.3