diff options
| author | Tim Graham <timograham@gmail.com> | 2014-10-31 13:34:41 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-10-31 13:38:00 -0400 |
| commit | 78af6f134b7df11773c4cb3597475cfbfe55277d (patch) | |
| tree | 1fe9ec0a21f4ab780f9e397402c3245a85d8562e | |
| parent | 4a30e0aeb9b9fc7d29cb574ae837afe429da6e20 (diff) | |
[1.6.x] Added a warning about direct settings manipulation in tests.
Thanks Thomas Chaumeny for the initial patch.
Backport of 3f651b3e88 from master
| -rw-r--r-- | docs/topics/testing/tools.txt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/docs/topics/testing/tools.txt b/docs/topics/testing/tools.txt index 6f770bd1b2..26ed8f8a7b 100644 --- a/docs/topics/testing/tools.txt +++ b/docs/topics/testing/tools.txt @@ -1044,6 +1044,12 @@ If ``multi_db=True``, fixtures are loaded into all databases. Overriding settings ~~~~~~~~~~~~~~~~~~~ +.. warning:: + + Use the functions below to temporarily alter the value of settings in tests. + Don't manipulate ``django.conf.settings`` directly as Django won't restore + the original values after such manipulations. + .. method:: SimpleTestCase.settings() For testing purposes it's often useful to change a setting temporarily and |
