MCPcopy Index your code
hub / github.com/python/cpython / test_async_gen_exception_06

Method test_async_gen_exception_06

Lib/test/test_asyncgen.py:260–267  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

258 to_list(gen())
259
260 def test_async_gen_exception_06(self):
261 async def gen():
262 yield 123
263 raise StopIteration
264
265 with self.assertRaisesRegex(RuntimeError,
266 'async generator.*StopIteration'):
267 to_list(gen())
268
269 def test_async_gen_exception_07(self):
270 def sync_gen():

Callers

nothing calls this directly

Calls 3

to_listFunction · 0.85
assertRaisesRegexMethod · 0.80
genFunction · 0.70

Tested by

no test coverage detected