mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-12 23:01:41 +00:00
test(proxy): stub watchfiles find_spec in reload override test
Without stubbing importlib.util.find_spec, the test fails in environments that lack the watchfiles package because _configure_dev_reload now emits an extra warning before the .env override warning.
This commit is contained in:
parent
e611e34bc0
commit
80c868a0ef
1 changed files with 7 additions and 1 deletions
|
|
@ -204,7 +204,13 @@ class TestProxyInitializationHelpers:
|
|||
monkeypatch.chdir(tmp_path)
|
||||
|
||||
uvicorn_args: dict = {}
|
||||
with patch("litellm._logging.verbose_proxy_logger.warning") as mock_warning:
|
||||
with (
|
||||
patch(
|
||||
"litellm.proxy.proxy_cli.importlib.util.find_spec",
|
||||
return_value=object(),
|
||||
),
|
||||
patch("litellm._logging.verbose_proxy_logger.warning") as mock_warning,
|
||||
):
|
||||
ProxyInitializationHelpers._configure_dev_reload(
|
||||
uvicorn_args, str(config_file)
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue