assert_empty_iter() — anthropic-sdk-python Function Reference
Architecture documentation for the assert_empty_iter() function in test_streaming.py from the anthropic-sdk-python codebase.
Entity Profile
Dependency Diagram
graph TD c5af313f_3e52_e64c_55cd_3f91d2287e41["assert_empty_iter()"] 2da79393_445f_321e_d12f_59a347c0de92["test_streaming.py"] c5af313f_3e52_e64c_55cd_3f91d2287e41 -->|defined in| 2da79393_445f_321e_d12f_59a347c0de92 9ba7b77c_2041_f85b_c8a9_8d706334f102["test_basic()"] 9ba7b77c_2041_f85b_c8a9_8d706334f102 -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 05d1245b_97b0_6c50_3ad7_415048b640c4["test_data_missing_event()"] 05d1245b_97b0_6c50_3ad7_415048b640c4 -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 6fdaa624_7911_f3bd_508e_3a3a3b41d90f["test_event_missing_data()"] 6fdaa624_7911_f3bd_508e_3a3a3b41d90f -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 89b4081c_caa5_bc15_c2c1_6f0a549ae87c["test_multiple_events()"] 89b4081c_caa5_bc15_c2c1_6f0a549ae87c -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 730feed6_74f5_12c5_ea44_2402762b38a6["test_multiple_events_with_data()"] 730feed6_74f5_12c5_ea44_2402762b38a6 -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 bc18ac09_bd91_a5fa_1a48_cb8bf74ade81["test_multiple_data_lines_with_empty_line()"] bc18ac09_bd91_a5fa_1a48_cb8bf74ade81 -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 a0534227_cea6_0f9f_1ca1_46d2d50033c4["test_data_json_escaped_double_new_line()"] a0534227_cea6_0f9f_1ca1_46d2d50033c4 -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 1cbd585a_e4e8_0cc8_6e82_2204a19ee08f["test_multiple_data_lines()"] 1cbd585a_e4e8_0cc8_6e82_2204a19ee08f -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 522ee4f1_a04e_9a01_9a92_868b8b2dbf4a["test_special_new_line_character()"] 522ee4f1_a04e_9a01_9a92_868b8b2dbf4a -->|calls| c5af313f_3e52_e64c_55cd_3f91d2287e41 e0c910ce_14e1_57db_2c86_d0aaa328f673["iter_next()"] c5af313f_3e52_e64c_55cd_3f91d2287e41 -->|calls| e0c910ce_14e1_57db_2c86_d0aaa328f673 style c5af313f_3e52_e64c_55cd_3f91d2287e41 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
tests/test_streaming.py lines 239–241
async def assert_empty_iter(iter: Iterator[ServerSentEvent] | AsyncIterator[ServerSentEvent]) -> None:
with pytest.raises((StopAsyncIteration, RuntimeError)):
await iter_next(iter)
Domain
Subdomains
Defined In
Calls
Called By
Source
Frequently Asked Questions
What does assert_empty_iter() do?
assert_empty_iter() is a function in the anthropic-sdk-python codebase, defined in tests/test_streaming.py.
Where is assert_empty_iter() defined?
assert_empty_iter() is defined in tests/test_streaming.py at line 239.
What does assert_empty_iter() call?
assert_empty_iter() calls 1 function(s): iter_next.
What calls assert_empty_iter()?
assert_empty_iter() is called by 9 function(s): test_basic, test_data_json_escaped_double_new_line, test_data_missing_event, test_event_missing_data, test_multiple_data_lines, test_multiple_data_lines_with_empty_line, test_multiple_events, test_multiple_events_with_data, and 1 more.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free