MCPcopy
hub / github.com/encode/starlette / homepage

Function homepage

tests/middleware/test_gzip.py:18–19  ·  view source on GitHub ↗
(request: Request)

Source from the content-addressed store, hash-verified

16
17def test_gzip_responses(test_client_factory: TestClientFactory) -> None:
18 def homepage(request: Request) -> PlainTextResponse:
19 return PlainTextResponse("x" * 4000, status_code=200)
20
21 app = Starlette(
22 routes=[Route("/", endpoint=homepage)],

Callers

nothing calls this directly

Calls 3

PlainTextResponseClass · 0.90
StreamingResponseClass · 0.90
generatorFunction · 0.85

Tested by

no test coverage detected