MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / assert_empty_iter

Function assert_empty_iter

tests/test_streaming.py:371–373  ·  view source on GitHub ↗
(iter: Iterator[ServerSentEvent] | AsyncIterator[ServerSentEvent])

Source from the content-addressed store, hash-verified

369 return next(iter)
370
371
372async def assert_empty_iter(iter: Iterator[ServerSentEvent] | AsyncIterator[ServerSentEvent]) -> None:
373 with pytest.raises((StopAsyncIteration, RuntimeError)):
374 await iter_next(iter)
375
376

Calls 1

iter_nextFunction · 0.70

Tested by

no test coverage detected