From 838899862f4fdac87194b090f930ed8d2b47ed9d Mon Sep 17 00:00:00 2001 From: shivam Date: Fri, 11 Sep 2026 03:22:10 +0000 Subject: [PATCH] test(otel): cover websocket forwarded headers Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> --- .../pass_through_endpoints/test_pass_through_endpoints.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_litellm/proxy/pass_through_endpoints/test_pass_through_endpoints.py b/tests/test_litellm/proxy/pass_through_endpoints/test_pass_through_endpoints.py index 9a474d691b1..dcc0d78fb7d 100644 --- a/tests/test_litellm/proxy/pass_through_endpoints/test_pass_through_endpoints.py +++ b/tests/test_litellm/proxy/pass_through_endpoints/test_pass_through_endpoints.py @@ -4903,7 +4903,7 @@ async def test_websocket_passthrough_propagates_active_trace_context(monkeypatch websocket.send_bytes = AsyncMock() websocket.receive = AsyncMock(return_value={"type": "websocket.disconnect"}) websocket.close = AsyncMock() - websocket.headers = {} + websocket.headers = {"authorization": "Bearer client"} websocket.client_state = WebSocketState.CONNECTED websocket.application_state = WebSocketState.CONNECTED tracer = TracerProvider().get_tracer("test") @@ -4931,7 +4931,7 @@ async def test_websocket_passthrough_propagates_active_trace_context(monkeypatch target="wss://upstream.example.test/v1/realtime", custom_headers={}, user_api_key_dict=UserAPIKeyAuth(), - forward_headers=False, + forward_headers=True, endpoint="/realtime", accept_websocket=True, )