forked from phoenix/litellm-mirror
build(test_python_38.py): add testing for litellm cli import
This commit is contained in:
parent
1b24beb7c7
commit
f0bee037ad
1 changed files with 15 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
|||
import sys, os, time
|
||||
import traceback, asyncio
|
||||
import pytest
|
||||
import subprocess
|
||||
|
||||
sys.path.insert(
|
||||
0, os.path.abspath("../..")
|
||||
|
@ -16,3 +17,17 @@ def test_using_litellm():
|
|||
pytest.fail(
|
||||
f"Error occurred: {e}. Installing litellm on python3.8 failed please retry"
|
||||
)
|
||||
|
||||
|
||||
def test_litellm_proxy_server():
|
||||
# Install the litellm[proxy] package
|
||||
subprocess.run(["pip", "install", "litellm[proxy]"])
|
||||
|
||||
# Import the proxy_server module
|
||||
try:
|
||||
import litellm.proxy.proxy_server
|
||||
except ImportError:
|
||||
pytest.fail("Failed to import litellm.proxy_server")
|
||||
|
||||
# Assertion to satisfy the test, you can add other checks as needed
|
||||
assert True
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue