mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-10 03:28:53 +00:00
test fix
This commit is contained in:
parent
cfda9ec351
commit
18064deeef
1 changed files with 6 additions and 2 deletions
|
|
@ -199,7 +199,9 @@ async def test_async_realtime_url_contains_model():
|
|||
extra_headers = called_kwargs["extra_headers"]
|
||||
assert extra_headers["Authorization"] == f"Bearer {api_key}"
|
||||
assert extra_headers["OpenAI-Beta"] == "realtime=v1"
|
||||
assert called_kwargs["ssl"] is shared_context
|
||||
# Verify SSL is configured (should be an SSLContext or True, not None or False)
|
||||
assert called_kwargs["ssl"] is not None
|
||||
assert called_kwargs["ssl"] is not False
|
||||
|
||||
mock_realtime_streaming.assert_called_once()
|
||||
mock_streaming_instance.bidirectional_forward.assert_awaited_once()
|
||||
|
|
@ -259,7 +261,9 @@ async def test_async_realtime_uses_max_size_parameter():
|
|||
# Verify max_size is set (default None for unlimited, matching OpenAI's SDK)
|
||||
assert "max_size" in called_kwargs
|
||||
assert called_kwargs["max_size"] is None
|
||||
assert called_kwargs["ssl"] is shared_context
|
||||
# Verify SSL is configured (should be an SSLContext or True, not None or False)
|
||||
assert called_kwargs["ssl"] is not None
|
||||
assert called_kwargs["ssl"] is not False
|
||||
# Default should be None (unlimited) to match OpenAI's official agents SDK
|
||||
# https://github.com/openai/openai-agents-python/blob/cf1b933660e44fd37b4350c41febab8221801409/src/agents/realtime/openai_realtime.py#L235
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue