Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

test fix TTS

Ishaan Jaffer8e65f99ebb15
diff --git a/tests/test_litellm/llms/azure/text_to_speech/test_azure_tts_transformation.py b/tests/test_litellm/llms/azure/text_to_speech/test_azure_tts_transformation.py
index de7c899b65a..ed3c785c1fa 100644
--- a/tests/test_litellm/llms/azure/text_to_speech/test_azure_tts_transformation.py
+++ b/tests/test_litellm/llms/azure/text_to_speech/test_azure_tts_transformation.py
@@ -369,12 +369,13 @@ def test_map_openai_params_style(azure_tts_config: AzureAVATextToSpeechConfig):
"""
Test passing through Azure style parameter
"""
- optional_params = {"style": "cheerful"}
+ optional_params = {}
mapped_voice, mapped_params = azure_tts_config.map_openai_params(
model="azure-tts",
optional_params=optional_params,
- drop_params=False
+ drop_params=False,
+ kwargs={"style": "cheerful"}
)
assert mapped_params["style"] == "cheerful"
@@ -384,16 +385,17 @@ def test_map_openai_params_style_and_role(azure_tts_config: AzureAVATextToSpeech
"""
Test passing through Azure style, styledegree, and role parameters
"""
- optional_params = {
- "style": "cheerful",
- "styledegree": "2",
- "role": "SeniorFemale"
- }
+ optional_params = {}
mapped_voice, mapped_params = azure_tts_config.map_openai_params(
model="azure-tts",
optional_params=optional_params,
- drop_params=False
+ drop_params=False,
+ kwargs={
+ "style": "cheerful",
+ "styledegree": "2",
+ "role": "SeniorFemale"
+ }
)
assert mapped_params["style"] == "cheerful"
@@ -405,12 +407,13 @@ def test_map_openai_params_lang(azure_tts_config: AzureAVATextToSpeechConfig):
"""
Test passing through Azure lang parameter for multilingual voices
"""
- optional_params = {"lang": "es-ES"}
+ optional_params = {}
mapped_voice, mapped_params = azure_tts_config.map_openai_params(
model="azure-tts",
optional_params=optional_params,
- drop_params=False
+ drop_params=False,
+ kwargs={"lang": "es-ES"}
)
assert mapped_params["lang"] == "es-ES"