test(test_router.py): add test to ensure error is correctly re-raised

This commit is contained in:
Krrish Dholakia 2024-08-24 10:08:14 -07:00
parent 0b06a76cf9
commit 5a2c9d5121
2 changed files with 41 additions and 13 deletions

View file

@ -503,7 +503,6 @@ def mock_completion(
):
raise litellm.RateLimitError(
message="this is a mock rate limit error",
status_code=getattr(mock_response, "status_code", 429), # type: ignore
llm_provider=getattr(mock_response, "llm_provider", custom_llm_provider or "openai"), # type: ignore
model=model,
)