diff options
author | David Smith <smithdc@gmail.com> | 2023-02-01 07:13:39 +0000 |
---|---|---|
committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2023-02-01 11:04:38 +0100 |
commit | 097e3a70c1481ee7b042b2edd91b2be86fb7b5b6 (patch) | |
tree | 7042be9ee3aabda10ecfa8923a113388b81f34a8 /tests/transactions | |
parent | 8c660fb59239828583f17cdede3b64f208b8752c (diff) | |
download | django-097e3a70c1481ee7b042b2edd91b2be86fb7b5b6.tar.gz |
Refs #33476 -- Applied Black's 2023 stable style.
Black 23.1.0 is released which, as the first release of the year,
introduces the 2023 stable style. This incorporates most of last year's
preview style.
https://github.com/psf/black/releases/tag/23.1.0
Diffstat (limited to 'tests/transactions')
-rw-r--r-- | tests/transactions/tests.py | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/tests/transactions/tests.py b/tests/transactions/tests.py index 1f2634224b..2419eb47f2 100644 --- a/tests/transactions/tests.py +++ b/tests/transactions/tests.py @@ -319,7 +319,6 @@ class AtomicMergeTests(TransactionTestCase): @skipUnlessDBFeature("uses_savepoints") class AtomicErrorsTests(TransactionTestCase): - available_apps = ["transactions"] forbidden_atomic_msg = "This is forbidden when an 'atomic' block is active." @@ -392,7 +391,6 @@ class AtomicErrorsTests(TransactionTestCase): @skipUnlessDBFeature("uses_savepoints") @skipUnless(connection.vendor == "mysql", "MySQL-specific behaviors") class AtomicMySQLTests(TransactionTestCase): - available_apps = ["transactions"] @skipIf(threading is None, "Test requires threading") @@ -433,7 +431,6 @@ class AtomicMySQLTests(TransactionTestCase): class AtomicMiscTests(TransactionTestCase): - available_apps = ["transactions"] def test_wrap_callable_instance(self): @@ -453,13 +450,10 @@ class AtomicMiscTests(TransactionTestCase): # Expect an error when rolling back a savepoint that doesn't exist. # Done outside of the transaction block to ensure proper recovery. with self.assertRaises(Error): - # Start a plain transaction. with transaction.atomic(): - # Swallow the intentional error raised in the sub-transaction. with self.assertRaisesMessage(Exception, "Oops"): - # Start a sub-transaction with a savepoint. with transaction.atomic(): sid = connection.savepoint_ids[-1] @@ -470,14 +464,11 @@ class AtomicMiscTests(TransactionTestCase): def test_mark_for_rollback_on_error_in_transaction(self): with transaction.atomic(savepoint=False): - # Swallow the intentional error raised. with self.assertRaisesMessage(Exception, "Oops"): - # Wrap in `mark_for_rollback_on_error` to check if the # transaction is marked broken. with transaction.mark_for_rollback_on_error(): - # Ensure that we are still in a good state. self.assertFalse(transaction.get_rollback()) @@ -500,11 +491,9 @@ class AtomicMiscTests(TransactionTestCase): # Swallow the intentional error raised. with self.assertRaisesMessage(Exception, "Oops"): - # Wrap in `mark_for_rollback_on_error` to check if the transaction # is marked broken. with transaction.mark_for_rollback_on_error(): - # Ensure that we are still in a good state. self.assertFalse(transaction.get_connection().needs_rollback) @@ -519,7 +508,6 @@ class AtomicMiscTests(TransactionTestCase): class NonAutocommitTests(TransactionTestCase): - available_apps = [] def setUp(self): |