diff options
| author | Ramiro Morales <cramm0@gmail.com> | 2013-06-01 14:24:46 -0300 |
|---|---|---|
| committer | Ramiro Morales <cramm0@gmail.com> | 2013-08-31 11:02:32 -0300 |
| commit | e909ceae9b3e72b72e0a2baaa92bba9714f18cd2 (patch) | |
| tree | b1c8cdcd1b876b4490036705b8ee0e8bab5df904 /docs/topics | |
| parent | e0643cb676d2b7f3219c9bf6ac2c2f990eee6899 (diff) | |
Made django.test.testcases not depend on staticfiles contrib app.
Do this by introducing a django.contrib.staticfiles.testing.StaticLiveServerCase
unittest TestCase subclass.
Fixes #20739.
Diffstat (limited to 'docs/topics')
| -rw-r--r-- | docs/topics/testing/overview.txt | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/docs/topics/testing/overview.txt b/docs/topics/testing/overview.txt index 89b38f7573..d7af823038 100644 --- a/docs/topics/testing/overview.txt +++ b/docs/topics/testing/overview.txt @@ -1041,11 +1041,25 @@ out the `full reference`_ for more details. .. _full reference: http://selenium-python.readthedocs.org/en/latest/api.html .. _Firefox: http://www.mozilla.com/firefox/ -.. note:: +.. versionchanged:: 1.7 + + Before Django 1.7 ``LiveServerTestCase`` used to rely on the + :doc:`staticfiles contrib app </howto/static-files/index>` to get the + static assets of the application(s) under test transparently served at their + expected locations during the execution of these tests. + + In Django 1.7 this dependency of core functionality on a ``contrib`` + appplication has been removed, because of which ``LiveServerTestCase`` + ability in this respect has been retrofitted to simply publish the contents + of the file system under :setting:`STATIC_ROOT` at the :setting:`STATIC_URL` + URL. - ``LiveServerTestCase`` makes use of the :doc:`staticfiles contrib app - </howto/static-files/index>` so you'll need to have your project configured - accordingly (in particular by setting :setting:`STATIC_URL`). + If you use the ``staticfiles`` app in your project and need to perform live + testing then you might want to consider using the + :class:`~django.contrib.staticfiles.testing.StaticLiveServerCase` subclass + shipped with it instead because it's the one that implements the original + behavior now. See :ref:`the relevant documentation + <staticfiles-testing-support>` for more details. .. note:: |
