mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-09 03:18:44 +00:00
test_openai_azure_embedding_optional_arg
This commit is contained in:
parent
0efb0e2990
commit
b97e56252d
1 changed files with 9 additions and 1 deletions
|
|
@ -380,8 +380,16 @@ def test_openai_azure_embedding_optional_arg():
|
|||
azure_ad_token="test",
|
||||
)
|
||||
|
||||
assert mock_client.called_once_with(model="test", input=["test"], timeout=600)
|
||||
mock_client.assert_called_once_with(
|
||||
model="test",
|
||||
input=["test"],
|
||||
extra_body={"azure_ad_token": "test"},
|
||||
timeout=600,
|
||||
extra_headers={"X-Stainless-Raw-Response": "true"}
|
||||
)
|
||||
# Verify azure_ad_token is passed in extra_body, not as a direct parameter
|
||||
assert "azure_ad_token" not in mock_client.call_args.kwargs
|
||||
assert mock_client.call_args.kwargs["extra_body"]["azure_ad_token"] == "test"
|
||||
|
||||
|
||||
# test_openai_azure_embedding()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue