litellm/tests/unit/proxy
yuneng-jiang 7fc2206171
test: fix stale and state-leaking tests red on scheduled CircleCI (#43266)
test_update_config_success_callback_normalization replaced
proxy_server.proxy_logging_obj with a MagicMock and never restored it.
Since the proxy unit tests joined tests/unit (#42903), 14 JWT mapping,
end-user and MCP tests on the same xdist worker awaited that mock and
failed. The test now uses monkeypatch.

test_prometheus_logging_callbacks set verbose_logger to DEBUG and
litellm.set_verbose at import, so every worker in the unit job ran with
DEBUG on. That broke caplog equality in the JEV classifier test, the
vertex streaming memory ratio, and four event-loop lag checks. The
module-level setup is removed; nothing in the file depended on it.

#43081 removed the OCR harness modules but left them in the
importability parametrize list.

test_get_model_info_bedrock_region reassigned litellm.model_cost and set
LITELLM_LOCAL_MODEL_COST_MAP without restoring either, and never cleared
the get_model_info caches, so it failed whenever an earlier test had
looked up the regional model. It now uses monkeypatch and invalidates
the caches; the local_testing isolation fixture also invalidates them
after restoring model_cost.

The Windows job hit CircleCI's 10 minute no-output limit while cargo
compiles the Rust crates inside uv sync and uv build. Those two steps now
allow 30 minutes of silence.
2026-09-25 19:10:20 -07:00
..
_experimental feat(mcp): configure protocol versions and capability discovery (#43169) 2026-09-25 13:13:52 -07:00
auth
common_utils fix(proxy): keep the submitted body out of 422 validation errors (#43231) 2026-09-25 17:05:53 -07:00
db
example_config_yaml
google_endpoints
hooks fix(router): await budget redis pipeline before sync reads (internal copy of #32618) (#43125) 2026-09-24 22:27:13 -07:00
management_endpoints
management_helpers
middleware
public_endpoints
response_polling
spend_tracking
test_configs
__init__.py
conftest.py
test_aproxy_startup.py
test_custom_callback_input.py
test_custom_logger_s3_gcs.py
test_custom_tokenizer_bug.py
test_db_schema_changes.py
test_deprecated_key_grace_period.py
test_get_favicon.py
test_get_image.py
test_prisma_client_backoff_retry.py
test_prompt_test_endpoint.py
test_proxy_config_unit_test.py
test_proxy_custom_auth.py
test_proxy_reject_logging.py
test_proxy_server.py test: fix stale and state-leaking tests red on scheduled CircleCI (#43266) 2026-09-25 19:10:20 -07:00
test_proxy_setting_guardrails.py
test_proxy_token_counter.py
test_proxy_utils.py
test_reducto_ocr_route.py
test_response_polling_pre_call_checks.py
test_server_root_path.py
test_ui_path_detection.py
test_unit_test_proxy_hooks.py
test_update_spend.py
test_zero_cost_model_budget_bypass.py
vertex_key.json