test(test_rules.py): fix test
This commit is contained in:
parent
a456f6bf2b
commit
e8437e52fa
@ -132,12 +132,15 @@ def test_post_call_rule_streaming():
|
||||
)
|
||||
|
||||
|
||||
def test_post_call_processing_error_async_response():
|
||||
response = asyncio.run(
|
||||
acompletion(
|
||||
@pytest.mark.asyncio
|
||||
async def test_post_call_processing_error_async_response():
|
||||
try:
|
||||
response = await acompletion(
|
||||
model="command-nightly", # Just used as an example
|
||||
messages=[{"content": "Hello, how are you?", "role": "user"}],
|
||||
api_base="https://openai-proxy.berriai.repl.co", # Just used as an example
|
||||
custom_llm_provider="openai",
|
||||
)
|
||||
)
|
||||
pytest.fail("This call should have failed")
|
||||
except Exception as e:
|
||||
pass
|
||||
|
||||
Loading…
Reference in New Issue
Block a user