mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-08 22:21:35 +00:00
test(anthropic): fix PT012 lint violation in upstream-error regression test
This commit is contained in:
parent
b2df72f980
commit
e1fece511a
1 changed files with 5 additions and 1 deletions
|
|
@ -501,10 +501,14 @@ async def test_async_sse_wrapper_reraises_upstream_error_to_connected_client():
|
|||
)
|
||||
|
||||
received = []
|
||||
with pytest.raises(_ProviderStreamError) as excinfo:
|
||||
|
||||
async def _drain():
|
||||
async for chunk in iterator.async_sse_wrapper(_failing_stream()):
|
||||
received.append(chunk)
|
||||
|
||||
with pytest.raises(_ProviderStreamError) as excinfo:
|
||||
await _drain()
|
||||
|
||||
assert excinfo.value.status_code == 529
|
||||
assert received
|
||||
assert not any(c.startswith(b"event: error\n") for c in received)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue