mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-16 20:18:21 +00:00
fix: update tests to match tuple return type for cached init params
This commit is contained in:
@@ -146,12 +146,12 @@ def test_precomputed_init_params_match_inspect_signature():
|
||||
_OPENAI_INIT_PARAMS,
|
||||
)
|
||||
|
||||
expected_openai = [
|
||||
expected_openai = tuple(
|
||||
p for p in inspect.signature(OpenAI.__init__).parameters if p != "self"
|
||||
]
|
||||
expected_azure = [
|
||||
)
|
||||
expected_azure = tuple(
|
||||
p for p in inspect.signature(AzureOpenAI.__init__).parameters if p != "self"
|
||||
]
|
||||
)
|
||||
|
||||
assert _OPENAI_INIT_PARAMS == expected_openai
|
||||
assert _AZURE_OPENAI_INIT_PARAMS == expected_azure
|
||||
@@ -161,6 +161,6 @@ def test_precomputed_init_params_match_inspect_signature():
|
||||
def test_get_openai_client_initialization_param_fields(client_type):
|
||||
"""Verify the method returns the correct pre-computed params for each client type."""
|
||||
result = BaseOpenAILLM.get_openai_client_initialization_param_fields(client_type)
|
||||
assert isinstance(result, list)
|
||||
assert isinstance(result, tuple)
|
||||
assert len(result) > 0
|
||||
assert "self" not in result
|
||||
|
||||
Reference in New Issue
Block a user