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]

[Proxy] Litellm fix mapped tests (#13634)

Jugal D. Bhatt3a38912bcea0
diff --git a/tests/enterprise/litellm_enterprise/proxy/hooks/test_managed_files.py b/tests/enterprise/litellm_enterprise/proxy/hooks/test_managed_files.py
index 305bd19a83f..032bd03a547 100644
--- a/tests/enterprise/litellm_enterprise/proxy/hooks/test_managed_files.py
+++ b/tests/enterprise/litellm_enterprise/proxy/hooks/test_managed_files.py
@@ -387,11 +387,9 @@ async def test_async_post_call_success_hook_twice_assert_no_unique_violation():
from litellm.proxy._types import UserAPIKeyAuth
from openai.types.batch import BatchRequestCounts
- prisma_client = PrismaClient(
- database_url=os.environ["DATABASE_URL"], proxy_logging_obj=proxy_logging_obj
- )
- await prisma_client.connect()
-
+ # Use AsyncMock instead of real database connection
+ prisma_client = AsyncMock()
+
batch = LiteLLMBatch(
id="bGl0ZWxsbV9wcm94eTttb2RlbF9pZDoxMjM0NTY3OTtsbG1fYmF0Y2hfaWQ6YmF0Y2hfNjg1YzVlNWQ2Mzk4ODE5MGI4NWJkYjIxNDdiYTEzMWQ",
completion_window="24h",