mirror of
https://github.com/django/daphne.git
synced 2025-07-11 08:22:17 +03:00
Fix bad rename stuff
This commit is contained in:
parent
841e19da79
commit
18385d68f0
|
@ -194,7 +194,7 @@ class Include(object):
|
||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(self, routing, **kwargs):
|
def __init__(self, routing, **kwargs):
|
||||||
self.routing = Routing.resolve_routing(routing)
|
self.routing = Router.resolve_routing(routing)
|
||||||
self.prefixes = kwargs
|
self.prefixes = kwargs
|
||||||
# Sanity check prefix regexes
|
# Sanity check prefix regexes
|
||||||
for name, value in self.prefixes.items():
|
for name, value in self.prefixes.items():
|
||||||
|
|
|
@ -215,7 +215,7 @@ class RoutingTests(SimpleTestCase):
|
||||||
Tests that regexes with positional groups are rejected.
|
Tests that regexes with positional groups are rejected.
|
||||||
"""
|
"""
|
||||||
with self.assertRaises(ValueError):
|
with self.assertRaises(ValueError):
|
||||||
Consumerrouter([
|
Router([
|
||||||
route("http.request", consumer_1, path=r"^/chat/([^/]+)/$"),
|
route("http.request", consumer_1, path=r"^/chat/([^/]+)/$"),
|
||||||
])
|
])
|
||||||
|
|
||||||
|
@ -225,10 +225,10 @@ class RoutingTests(SimpleTestCase):
|
||||||
starting with ^, and the included filter not starting with ^.
|
starting with ^, and the included filter not starting with ^.
|
||||||
"""
|
"""
|
||||||
with self.assertRaises(ValueError):
|
with self.assertRaises(ValueError):
|
||||||
Consumerrouter([
|
Router([
|
||||||
include("channels.tests.test_routing.chatroom_routing", path="foobar"),
|
include("channels.tests.test_routing.chatroom_routing", path="foobar"),
|
||||||
])
|
])
|
||||||
with self.assertRaises(ValueError):
|
with self.assertRaises(ValueError):
|
||||||
Consumerrouter([
|
Router([
|
||||||
include("channels.tests.test_routing.chatroom_routing_noprefix", path="^/foobar/"),
|
include("channels.tests.test_routing.chatroom_routing_noprefix", path="^/foobar/"),
|
||||||
])
|
])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user