MCPcopy Create free account
hub / github.com/pallets/quart / test_http_asgi_scope_from_request

Function test_http_asgi_scope_from_request

tests/test_asgi.py:309–322  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

307
308
309def test_http_asgi_scope_from_request() -> None:
310 app = Quart(__name__)
311 scope = {
312 "headers": [(b"host", b"quart")],
313 "http_version": "1.0",
314 "method": "GET",
315 "scheme": "https",
316 "path": "/",
317 "query_string": b"",
318 "test_result": "PASSED",
319 }
320 connection = ASGIHTTPConnection(app, scope) # type: ignore
321 request = connection._create_request_from_scope(lambda: None) # type: ignore
322 assert request.scope["test_result"] == "PASSED" # type: ignore
323
324
325@pytest.mark.parametrize(

Callers

nothing calls this directly

Calls 3

QuartClass · 0.90
ASGIHTTPConnectionClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…