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

Method test_add_with_tailing_slash

tests/test_urldispatch.py:135–142  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

133 self.assertEqual('name', info.route.name)
134
135 def test_add_with_tailing_slash(self):
136 handler = self.make_handler()
137 self.router.add_route('GET', '/handler/to/path/', handler)
138 req = self.make_request('GET', '/handler/to/path/')
139 info = self.loop.run_until_complete(self.router.resolve(req))
140 self.assertIsNotNone(info)
141 self.assertEqual({}, info)
142 self.assertIs(handler, info.handler)
143
144 def test_add_invalid_path(self):
145 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