(self)
| 41 | await self.con.execute('DROP TABLE mytab') |
| 42 | |
| 43 | async def test_execute_script_3(self): |
| 44 | with self.assertRaisesRegex(asyncpg.PostgresSyntaxError, |
| 45 | 'cannot insert multiple commands'): |
| 46 | |
| 47 | await self.con.execute(''' |
| 48 | CREATE TABLE mytab (a int); |
| 49 | INSERT INTO mytab (a) VALUES ($1), ($2); |
| 50 | ''', 10, 20) |
| 51 | |
| 52 | async def test_execute_script_check_transactionality(self): |
| 53 | with self.assertRaises(asyncpg.PostgresError): |