MCPcopy
hub / github.com/psycopg/psycopg / test_autocommit_unknown

Function test_autocommit_unknown

tests/test_connection.py:493–498  ·  view source on GitHub ↗
(conn)

Source from the content-addressed store, hash-verified

491
492
493def test_autocommit_unknown(conn):
494 conn.close()
495 assert conn.pgconn.transaction_status == pq.TransactionStatus.UNKNOWN
496 with pytest.raises(psycopg.OperationalError):
497 conn.set_autocommit(True)
498 assert not conn.autocommit
499
500
501@pytest.mark.parametrize(

Callers

nothing calls this directly

Calls 2

closeMethod · 0.45
set_autocommitMethod · 0.45

Tested by

no test coverage detected