mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 03:34:10 +00:00
test get mode info for gemini/gemini-1.5-flash
This commit is contained in:
parent
a16cd02cd9
commit
f20a8ff364
1 changed files with 11 additions and 2 deletions
|
@ -1,13 +1,16 @@
|
||||||
# What is this?
|
# What is this?
|
||||||
## Unit testing for the 'get_model_info()' function
|
## Unit testing for the 'get_model_info()' function
|
||||||
import os, sys, traceback
|
import os
|
||||||
|
import sys
|
||||||
|
import traceback
|
||||||
|
|
||||||
sys.path.insert(
|
sys.path.insert(
|
||||||
0, os.path.abspath("../..")
|
0, os.path.abspath("../..")
|
||||||
) # Adds the parent directory to the system path
|
) # Adds the parent directory to the system path
|
||||||
|
import pytest
|
||||||
|
|
||||||
import litellm
|
import litellm
|
||||||
from litellm import get_model_info
|
from litellm import get_model_info
|
||||||
import pytest
|
|
||||||
|
|
||||||
|
|
||||||
def test_get_model_info_simple_model_name():
|
def test_get_model_info_simple_model_name():
|
||||||
|
@ -37,3 +40,9 @@ def test_get_model_info_custom_llm_with_same_name_vllm():
|
||||||
pytest.fail("Expected get model info to fail for an unmapped model/provider")
|
pytest.fail("Expected get model info to fail for an unmapped model/provider")
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_model_info_shows_correct_supports_vision():
|
||||||
|
info = litellm.get_model_info("gemini/gemini-1.5-flash")
|
||||||
|
print("info", info)
|
||||||
|
assert info["supports_vision"] is True
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue