litellm/tests/test_litellm/llms/zai
yuneng-jiang 3ac339cfbb
test: stop the zai tests from leaking env and litellm globals into the session (#37834)
test_zai_provider.py set LITELLM_LOCAL_MODEL_COST_MAP and litellm.model_cost
directly and never put them back, so every test that ran after it in the same
process saw a local cost map instead of the real one. The two respx tests did
the same to litellm.disable_aiohttp_transport with no restore at all.

Both now go through monkeypatch, which restores on teardown including when the
test fails. The cost-map setup moves into a fixture requested by exactly the
five tests that read the cost map.
2026-08-21 22:10:34 -07:00
..
test_zai_provider.py test: stop the zai tests from leaking env and litellm globals into the session (#37834) 2026-08-21 22:10:34 -07:00