1
0
mirror of https://github.com/django/django.git synced 2025-06-05 11:39:13 +00:00

[1.8.x] Simplified a versionchanged notes for LiveServerTestCase.

This commit is contained in:
Tim Graham 2015-02-01 21:06:27 -05:00
parent c9df163d0c
commit 6d0538bd8c

View File

@ -847,23 +847,15 @@ out the `full reference`_ for more details.
.. versionchanged:: 1.7 .. versionchanged:: 1.7
Before Django 1.7 ``LiveServerTestCase`` used to rely on the In older versions, ``LiveServerTestCase`` relied on the :doc:`staticfiles
:doc:`staticfiles contrib app </howto/static-files/index>` to get the contrib app </howto/static-files/index>` to transparently serve static
static assets of the application(s) under test transparently served at their files during the execution of tests. This functionality has been moved to
expected locations during the execution of these tests. the :class:`~django.contrib.staticfiles.testing.StaticLiveServerTestCase`
subclass, so use that subclass if you need :ref:`the original behavior
<staticfiles-testing-support>`.
In Django 1.7 this dependency of core functionality on a ``contrib`` ``LiveServerTestCase`` now simply publishes the contents of the file system
application has been removed, because of which ``LiveServerTestCase`` under :setting:`STATIC_ROOT` at the :setting:`STATIC_URL`.
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.
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.StaticLiveServerTestCase`
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:: .. note::