mirror of
https://github.com/tiennm99/litellm.git
synced 2026-06-18 17:28:19 +00:00
9711e3adfe
The conftest fixtures were saving/restoring the current (potentially contaminated) values of litellm globals like num_retries instead of resetting to true defaults. Under xdist, module-level assignments (e.g. `litellm.num_retries = 3` in 12+ test files) pollute the shared module state and leak across tests in the same worker. - Capture true litellm defaults at conftest import time and reset before each test (local_testing + llm_translation) - Make llm_translation/conftest.py xdist-safe (skip reload, add state isolation) - Replace asyncio.sleep(2) with polling in cooldown handler tests - Add @pytest.mark.flaky to tests making real API calls under xdist Co-Authored-By: Claude Opus 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.