MCPcopy
hub / github.com/psycopg/psycopg / test_cancel_fails_prepared

Method test_cancel_fails_prepared

tests/test_tpc_async.py:283–289  ·  view source on GitHub ↗
(self, aconn, tpc)

Source from the content-addressed store, hash-verified

281 assert xid.bqual is None
282
283 async def test_cancel_fails_prepared(self, aconn, tpc):
284 await aconn.tpc_begin("cancel")
285 await aconn.tpc_prepare()
286 with pytest.raises(psycopg.ProgrammingError):
287 aconn.cancel()
288 with pytest.raises(psycopg.ProgrammingError):
289 await aconn.cancel_safe()
290
291 async def test_tpc_recover_non_dbapi_connection(self, aconn_cls, aconn, dsn, tpc):
292 aconn.row_factory = psycopg.rows.dict_row

Callers

nothing calls this directly

Calls 4

tpc_beginMethod · 0.45
tpc_prepareMethod · 0.45
cancelMethod · 0.45
cancel_safeMethod · 0.45

Tested by

no test coverage detected