mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-07 08:26:10 +00:00
test(sso): keep the debug-page outage test on the capture-gap path
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
parent
237adf32e5
commit
9db85f553d
1 changed files with 6 additions and 7 deletions
|
|
@ -8274,18 +8274,17 @@ async def test_debug_page_is_byte_identical_when_no_id_jag_server_is_registered(
|
|||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_debug_page_survives_a_store_outage(caplog):
|
||||
async def test_debug_page_survives_a_store_outage(monkeypatch, caplog):
|
||||
"""The page's job is to render claims; an unreachable MCP table must cost it the annotation,
|
||||
not the page."""
|
||||
from litellm.proxy.management_endpoints.ui_sso import warn_if_id_jag_capture_gap
|
||||
|
||||
monkeypatch.setenv("GOOGLE_CLIENT_ID", _GOOGLE_DEBUG_CLIENT_ID)
|
||||
retention_check = AsyncMock(side_effect=Exception("db down"))
|
||||
with caplog.at_level(logging.WARNING, logger="LiteLLM Proxy"):
|
||||
assert (
|
||||
await warn_if_id_jag_capture_gap(
|
||||
retention_enabled=AsyncMock(side_effect=Exception("db down"))
|
||||
)
|
||||
is None
|
||||
)
|
||||
assert await warn_if_id_jag_capture_gap(retention_enabled=retention_check) is None
|
||||
|
||||
retention_check.assert_awaited_once()
|
||||
|
||||
assert _id_jag_gap_warnings(caplog) == []
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue