From 6d154e2317a4f4984d51b2e87ac73bb4e8814062 Mon Sep 17 00:00:00 2001 From: Marc Abramowitz Date: Thu, 2 May 2024 14:50:46 -0700 Subject: [PATCH] Update tests to reflect new error messages --- litellm/tests/test_proxy_exception_mapping.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/litellm/tests/test_proxy_exception_mapping.py b/litellm/tests/test_proxy_exception_mapping.py index 82957b658c..0cc7b0d30d 100644 --- a/litellm/tests/test_proxy_exception_mapping.py +++ b/litellm/tests/test_proxy_exception_mapping.py @@ -169,7 +169,7 @@ def test_chat_completion_exception_any_model(client): ) assert isinstance(openai_exception, openai.BadRequestError) _error_message = openai_exception.message - assert "Invalid model name passed in model=Lite-GPT-12" in str(_error_message) + assert "chat_completion: Invalid model name passed in model=Lite-GPT-12" in str(_error_message) except Exception as e: pytest.fail(f"LiteLLM Proxy test failed. Exception {str(e)}") @@ -197,7 +197,7 @@ def test_embedding_exception_any_model(client): print("Exception raised=", openai_exception) assert isinstance(openai_exception, openai.BadRequestError) _error_message = openai_exception.message - assert "Invalid model name passed in model=Lite-GPT-12" in str(_error_message) + assert "embeddings: Invalid model name passed in model=Lite-GPT-12" in str(_error_message) except Exception as e: pytest.fail(f"LiteLLM Proxy test failed. Exception {str(e)}")