mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-08 03:08:45 +00:00
test_message_with_name
This commit is contained in:
parent
4828fb1544
commit
0d398c2295
1 changed files with 12 additions and 9 deletions
|
|
@ -196,15 +196,18 @@ class BaseLLMChatTest(ABC):
|
|||
assert response is not None
|
||||
|
||||
def test_message_with_name(self):
|
||||
litellm.set_verbose = True
|
||||
base_completion_call_args = self.get_base_completion_call_args()
|
||||
messages = [
|
||||
{"role": "user", "content": "Hello", "name": "test_name"},
|
||||
]
|
||||
response = self.completion_function(
|
||||
**base_completion_call_args, messages=messages
|
||||
)
|
||||
assert response is not None
|
||||
try:
|
||||
litellm.set_verbose = True
|
||||
base_completion_call_args = self.get_base_completion_call_args()
|
||||
messages = [
|
||||
{"role": "user", "content": "Hello", "name": "test_name"},
|
||||
]
|
||||
response = self.completion_function(
|
||||
**base_completion_call_args, messages=messages
|
||||
)
|
||||
assert response is not None
|
||||
except litellm.RateLimitError:
|
||||
pass
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"response_format",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue