summaryrefslogtreecommitdiff
path: root/test/engine/test_transaction.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/engine/test_transaction.py')
-rw-r--r--test/engine/test_transaction.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/test/engine/test_transaction.py b/test/engine/test_transaction.py
index 01a561d7b..e3176a45a 100644
--- a/test/engine/test_transaction.py
+++ b/test/engine/test_transaction.py
@@ -77,7 +77,7 @@ class TransactionTest(TestBase):
result = connection.execute("select * from query_users")
assert len(result.fetchall()) == 0
connection.close()
-
+
def test_transaction_container(self):
def go(conn, table, data):
@@ -93,7 +93,7 @@ class TransactionTest(TestBase):
{'user_id': 1, 'user_name': 'user3'}])
eq_(testing.db.execute(users.select()).fetchall(), [(1, 'user1'
)])
-
+
def test_nested_rollback(self):
connection = testing.db.connect()
try:
@@ -138,7 +138,7 @@ class TransactionTest(TestBase):
eq_(connection.scalar("select count(*) from query_users"), 0)
finally:
connection.close()
-
+
def test_nesting(self):
connection = testing.db.connect()
transaction = connection.begin()
@@ -295,7 +295,7 @@ class TransactionTest(TestBase):
order_by(users.c.user_id)).fetchall(),
[(1, ), (2, ), (5, )])
connection.close()
-
+
@testing.requires.two_phase_transactions
@testing.crashes('mysql+oursql',
'Times out in full test runs only, causing '
@@ -350,7 +350,7 @@ class TransactionTest(TestBase):
order_by(users.c.user_id))
eq_(result.fetchall(), [('user1', ), ('user4', )])
conn.close()
-
+
class AutoRollbackTest(TestBase):
@classmethod
@@ -386,7 +386,7 @@ class AutoRollbackTest(TestBase):
class ExplicitAutoCommitTest(TestBase):
"""test the 'autocommit' flag on select() and text() objects.
-
+
Requires PostgreSQL so that we may define a custom function which
modifies the database. """
@@ -541,13 +541,13 @@ class TLTransactionTest(TestBase):
# ensure tests start with engine closed
tlengine.close()
-
+
def test_rollback_no_trans(self):
tlengine = create_engine(testing.db.url, strategy="threadlocal")
# shouldn't fail
tlengine.rollback()
-
+
tlengine.begin()
tlengine.rollback()
@@ -577,7 +577,7 @@ class TLTransactionTest(TestBase):
# shouldn't fail
tlengine.prepare()
-
+
def test_connection_close(self):
"""test that when connections are closed for real, transactions
are rolled back and disposed."""
@@ -993,11 +993,11 @@ class ForUpdateTest(TestBase):
@testing.requires.independent_connections
def test_queued_update(self):
"""Test SELECT FOR UPDATE with concurrent modifications.
-
+
Runs concurrent modifications on a single row in the users
table, with each mutator trying to increment a value stored in
user_name.
-
+
"""
db = testing.db