mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-15 04:32:22 +00:00
test_complete_reload_flow and test_distributed_reload_check_function both trigger code paths that assign a minimal stub dict to litellm.model_cost (via the /reload/model_cost_map endpoint and _check_and_reload_model_cost_map). Without restoring, subsequent tests in the same worker can't find gpt-4o pricing and calculate spend=0.0 instead of the expected value. Added try/finally save-and-restore of litellm.model_cost in both tests, matching the pattern used in test_reload_model_cost_map_admin_access. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
In total litellm runs 1000+ tests
[02/20/2025] Update:
To make it easier to contribute and map what behavior is tested,
we've started mapping the litellm directory in tests/test_litellm
This folder can only run mock tests.