MCPcopy
hub / github.com/aio-libs/aiohttp / test_waituntil

Function test_waituntil

tests/test_parser_buffer.py:208–218  ·  view source on GitHub ↗
(buf)

Source from the content-addressed store, hash-verified

206
207
208def test_waituntil(buf):
209 p = buf.waituntil(b'\n', 4)
210 next(p)
211 p.send(b'123')
212 try:
213 p.send(b'\n456')
214 except StopIteration as exc:
215 res = exc.value
216
217 assert res == b'123\n'
218 assert b'123\n456' == bytes(buf)
219
220
221def test_waituntil_exc(buf):

Callers

nothing calls this directly

Calls 2

waituntilMethod · 0.80
sendMethod · 0.45

Tested by

no test coverage detected