Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

[1.5.x] Fixed #15582 -- Documented how TransactionTestCase.multi_db a…

…ffects fixtures.

Thanks slinkp for the suggestion.

Backport of dd839a2 from master
  • Loading branch information...
commit 2b8519760e04ca0ef3c9989c36588dde93a8152a 1 parent 766fbd5
Tim Graham authored October 11, 2013

Showing 1 changed file with 9 additions and 0 deletions. Show diff stats Hide diff stats

  1. 9  docs/topics/testing/overview.txt
9  docs/topics/testing/overview.txt
@@ -1286,6 +1286,10 @@ This flush/load procedure is repeated for each test in the test case, so you
1286 1286
 can be certain that the outcome of a test will not be affected by another test,
1287 1287
 or by the order of test execution.
1288 1288
 
  1289
+By default, fixtures are only loaded into the ``default`` database. If you are
  1290
+using multiple databases and set :attr:`multi_db=True
  1291
+<TransactionTestCase.multi_db>`, fixtures will be loaded into all databases.
  1292
+
1289 1293
 URLconf configuration
1290 1294
 ~~~~~~~~~~~~~~~~~~~~~
1291 1295
 
@@ -1351,6 +1355,11 @@ For example::
1351 1355
 This test case will flush *all* the test databases before running
1352 1356
 ``testIndexPageView``.
1353 1357
 
  1358
+The ``multi_db`` flag also affects into which databases the
  1359
+attr:`TransactionTestCase.fixtures` are loaded. By default (when
  1360
+``multi_db=False``), fixtures are only loaded into the ``default`` database.
  1361
+If ``multi_db=True``, fixtures are loaded into all databases.
  1362
+
1354 1363
 .. _overriding-settings:
1355 1364
 
1356 1365
 Overriding settings

0 notes on commit 2b85197

Please sign in to comment.
Something went wrong with that request. Please try again.