diff --git a/frappe/tests/utils.py b/frappe/tests/utils.py index d5c25db26a..7d00a0c1f9 100644 --- a/frappe/tests/utils.py +++ b/frappe/tests/utils.py @@ -20,6 +20,7 @@ class FrappeTestCase(unittest.TestCase): def setUpClass(cls) -> None: # flush changes done so far to avoid flake frappe.db.commit() + frappe.db.begin() if cls.SHOW_TRANSACTION_COMMIT_WARNINGS: frappe.db.add_before_commit(_commit_watcher)