MCPcopy Create free account
hub / github.com/encode/starlette / test_streaming_response_unknown_size

Function test_streaming_response_unknown_size

tests/test_responses.py:592–598  ·  view source on GitHub ↗
(
    test_client_factory: TestClientFactory,
)

Source from the content-addressed store, hash-verified

590
591
592def test_streaming_response_unknown_size(
593 test_client_factory: TestClientFactory,
594) -> None:
595 app = StreamingResponse(content=iter(["hello", "world"]))
596 client: TestClient = test_client_factory(app)
597 response = client.get("/")
598 assert "content-length" not in response.headers
599
600
601def test_streaming_response_known_size(test_client_factory: TestClientFactory) -> None:

Callers

nothing calls this directly

Calls 3

StreamingResponseClass · 0.90
test_client_factoryFunction · 0.85
getMethod · 0.45

Tested by

no test coverage detected