mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-10 03:28:53 +00:00
fix: use asyncio.run() and remove unused pytest import in tests
Address review feedback: - Replace deprecated asyncio.get_event_loop().run_until_complete() with asyncio.run() - Remove unused pytest import
This commit is contained in:
parent
0c895e87f2
commit
4dfb55773b
1 changed files with 1 additions and 3 deletions
|
|
@ -8,8 +8,6 @@ everything else through unchanged.
|
|||
|
||||
import asyncio
|
||||
|
||||
import pytest
|
||||
|
||||
|
||||
# The middleware is defined at module scope in proxy_server.py alongside heavy
|
||||
# imports we don't want here. Re-implement the same class locally to test the
|
||||
|
|
@ -55,7 +53,7 @@ def _make_http_scope(path: str, raw_path: bytes | None = None) -> dict:
|
|||
|
||||
|
||||
def _run(coro):
|
||||
return asyncio.get_event_loop().run_until_complete(coro)
|
||||
return asyncio.run(coro)
|
||||
|
||||
|
||||
# ── tests ────────────────────────────────────────────────────────────────
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue