MCPcopy
hub / github.com/aio-libs/aiohttp / test_add_with_matchdict

Method test_add_with_matchdict

tests/test_urldispatch.py:116–124  ·  tests/test_urldispatch.py::TestUrlDispatcher.test_add_with_matchdict
(self)

Source from the content-addressed store, hash-verified

114 self.assertIsNone(info.route.name)
115
116 def test_add_with_matchdict(self):
117 handler = self.make_handler()
118 self.router.add_route(&class="cm">#x27;GETclass="st">', '/handler/{to}', handler)
119 req = self.make_request(&class="cm">#x27;GETclass="st">', '/handler/tail')
120 info = self.loop.run_until_complete(self.router.resolve(req))
121 self.assertIsNotNone(info)
122 self.assertEqual({&class="cm">#x27;toclass="st">': 'tail'}, info)
123 self.assertIs(handler, info.handler)
124 self.assertIsNone(info.route.name)
125
126 def test_add_with_name(self):
127 handler = self.make_handler()

Callers

nothing calls this directly

Calls 4

make_handlerMethod · 0.95
make_requestMethod · 0.95
add_routeMethod · 0.45
resolveMethod · 0.45

Tested by

no test coverage detected