We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 395e498 commit 43c6804Copy full SHA for 43c6804
1 file changed
tests/backends/base/test_base.py
@@ -9,6 +9,7 @@
9
TransactionTestCase,
10
skipUnlessDBFeature,
11
)
12
+from django.test.runner import DebugSQLTextTestResult
13
from django.test.utils import CaptureQueriesContext, override_settings
14
15
from ..models import Person, Square
@@ -134,6 +135,8 @@ def test_rollback_debug_log(self):
134
135
136
137
def test_no_logs_without_debug(self):
138
+ if isinstance(self._outcome.result, DebugSQLTextTestResult):
139
+ self.skipTest("--debug-sql interferes with this test")
140
with self.assertNoLogs("django.db.backends", "DEBUG"):
141
with self.assertRaises(Exception), transaction.atomic():
142
Person.objects.create(first_name="first", last_name="last")
0 commit comments