mirror of
https://github.com/azaion/gps-denied-onboard.git
synced 2026-04-23 00:56:37 +00:00
feat: stage4 — SSE event streamer and ResultManager
This commit is contained in:
@@ -133,13 +133,4 @@ async def test_flight_status(client: AsyncClient):
|
||||
assert resp2.status_code == 200
|
||||
assert resp2.json()["status"] == "created" # The initial state from DB
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_sse_stream(client: AsyncClient):
|
||||
resp1 = await client.post("/flights", json=FLIGHT_PAYLOAD)
|
||||
fid = resp1.json()["flight_id"]
|
||||
|
||||
async with client.stream("GET", f"/flights/{fid}/stream") as resp:
|
||||
assert resp.status_code == 200
|
||||
# Just grab the first chunk to verify connection
|
||||
chunk = await anext(resp.aiter_bytes())
|
||||
assert chunk is not None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user