(self)
| 487 | await self.con.execute('DROP TABLE copytab') |
| 488 | |
| 489 | async def test_copy_to_table_from_bytes_like(self): |
| 490 | await self.con.execute(''' |
| 491 | CREATE TABLE copytab(a text, b text); |
| 492 | ''') |
| 493 | |
| 494 | try: |
| 495 | data = memoryview((b'a1' * 500 + b'\t' + b'b1' * 500 + b'\n') * 2) |
| 496 | res = await self.con.copy_to_table('copytab', source=data) |
| 497 | self.assertEqual(res, 'COPY 2') |
| 498 | finally: |
| 499 | await self.con.execute('DROP TABLE copytab') |
| 500 | |
| 501 | async def test_copy_to_table_fail_in_source_1(self): |
| 502 | await self.con.execute(''' |
nothing calls this directly
no test coverage detected