mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-01 07:03:02 +00:00
* refactor(proxy): inject database repositories through per-repository dependencies Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(proxy): model Prisma client cleanup * test(rust): include NativeDatabase in bridge API surface --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
13 lines
403 B
Python
13 lines
403 B
Python
from typing import Final
|
|
|
|
import pytest
|
|
from starlette.requests import Request
|
|
|
|
from litellm.proxy.deps.database import DatabaseStateMissingError, get_database
|
|
|
|
|
|
@pytest.mark.asyncio
|
|
async def test_missing_lifespan_is_not_treated_as_a_disabled_database():
|
|
request: Final = Request({"type": "http", "state": {}})
|
|
with pytest.raises(DatabaseStateMissingError):
|
|
await get_database(request)
|