| 49 | @pytest.mark.anyio |
| 50 | async def test_iterate_in_threadpool() -> None: |
| 51 | class CustomIterable: |
| 52 | def __iter__(self) -> Iterator[int]: |
| 53 | yield from range(3) |
| 54 | |
| 55 | assert [v async for v in iterate_in_threadpool(CustomIterable())] == [0, 1, 2] |
no outgoing calls