summaryrefslogtreecommitdiff
path: root/docs/ref
diff options
context:
space:
mode:
authorMarc Tamlyn <marc.tamlyn@gmail.com>2015-01-10 22:52:59 +0000
committerMarc Tamlyn <marc.tamlyn@gmail.com>2015-01-12 08:16:08 +0000
commitb5c1a85b50c709770b8e98aeecfeb8e81ca29dcf (patch)
tree6291a3d178695605e808f4fa75b56e2553681f48 /docs/ref
parent68a439a18da17a65555832eff0a7c2090655b583 (diff)
Fixed #24118 -- Added --debug-sql option for tests.
Added a --debug-sql option for tests and runtests.py which outputs the SQL logger for failing tests. When combined with --verbosity=2, it also outputs the SQL for passing tests. Thanks to Berker, Tim, Markus, Shai, Josh and Anssi for review and discussion.
Diffstat (limited to 'docs/ref')
-rw-r--r--docs/ref/django-admin.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/ref/django-admin.txt b/docs/ref/django-admin.txt
index de556b28b7..570766f18d 100644
--- a/docs/ref/django-admin.txt
+++ b/docs/ref/django-admin.txt
@@ -1449,6 +1449,14 @@ This may help in debugging tests that aren't properly isolated and have side
effects. :ref:`Grouping by test class <order-of-tests>` is preserved when using
this option.
+.. django-admin-option:: --debug-sql
+
+.. versionadded:: 1.8
+
+The ``--debug-sql`` option can be used to enable :ref:`SQL logging
+<django-db-logger>` for failing tests. If :djadminopt:`--verbosity` is ``2``,
+then queries in passing tests are also output.
+
testserver <fixture fixture ...>
--------------------------------