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]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
Enhance team endpoint tests by integrating AsyncMock for cache methods, ensuring proper asynchronous behavior in test_update_team_guardrails_with_org_id. This improves test reliability and aligns with recent caching improvements.
harish-berri655e75276e15
diff --git a/tests/test_litellm/proxy/management_endpoints/test_team_endpoints.py b/tests/test_litellm/proxy/management_endpoints/test_team_endpoints.pyindex f1e077b5e4a..65015b9d6b6 100644--- a/tests/test_litellm/proxy/management_endpoints/test_team_endpoints.py+++ b/tests/test_litellm/proxy/management_endpoints/test_team_endpoints.py@@ -5151,6 +5151,9 @@ async def test_update_team_guardrails_with_org_id():return_value=mock_updated_team)mock_prisma.jsonify_team_object = MagicMock(side_effect=lambda db_data: db_data)+ # async_get_cache must be an AsyncMock so `await` in get_org_object works+ mock_cache.async_get_cache = AsyncMock(return_value=None)+ mock_cache.async_set_cache = AsyncMock()# Mock llm_routermock_router = MagicMock()