MCPcopy Create free account
hub / github.com/MagicStack/asyncpg / test_prepare_08_big_result

Method test_prepare_08_big_result

tests/test_prepare.py:120–127  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

118 self.con.terminate()
119
120 async def test_prepare_08_big_result(self):
121 stmt = await self.con.prepare('select generate_series(0,10000)')
122 result = await stmt.fetch()
123
124 self.assertEqual(len(result), 10001)
125 self.assertEqual(
126 [r[0] for r in result],
127 list(range(10001)))
128
129 async def test_prepare_09_raise_error(self):
130 # Stress test ReadBuffer.read_cstr()

Callers

nothing calls this directly

Calls 2

prepareMethod · 0.80
fetchMethod · 0.45

Tested by

no test coverage detected