summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2014-11-18 11:22:55 -0500
committerTim Graham <timograham@gmail.com>2015-01-17 07:32:22 -0500
commitb952c3fc606ed01c6d0ff26451b6e2acf1b91ca5 (patch)
tree2da59da14c459a84e55abe8df7ebe50f4404e515
parentce78b954cf2747add06dadd6aef8bbd70d70c667 (diff)
Removed django.utils.unittest per deprecation timeline.
-rw-r--r--django/utils/unittest.py13
-rw-r--r--docs/topics/testing/overview.txt14
-rw-r--r--setup.cfg2
-rw-r--r--tests/.coveragerc2
4 files changed, 2 insertions, 29 deletions
diff --git a/django/utils/unittest.py b/django/utils/unittest.py
deleted file mode 100644
index 8d337259ba..0000000000
--- a/django/utils/unittest.py
+++ /dev/null
@@ -1,13 +0,0 @@
-from __future__ import absolute_import
-
-import warnings
-
-from django.utils.deprecation import RemovedInDjango19Warning
-
-warnings.warn("django.utils.unittest will be removed in Django 1.9.",
- RemovedInDjango19Warning, stacklevel=2)
-
-try:
- from unittest2 import *
-except ImportError:
- from unittest import *
diff --git a/docs/topics/testing/overview.txt b/docs/topics/testing/overview.txt
index bd4216e029..0aca7fb0a4 100644
--- a/docs/topics/testing/overview.txt
+++ b/docs/topics/testing/overview.txt
@@ -20,20 +20,6 @@ Writing tests
Django's unit tests use a Python standard library module: :mod:`unittest`. This
module defines tests using a class-based approach.
-.. admonition:: unittest2
-
- .. deprecated:: 1.7
-
- Python 2.7 introduced some major changes to the ``unittest`` library,
- adding some extremely useful features. To ensure that every Django project
- could benefit from these new features, Django used to ship with a copy of
- Python 2.7's ``unittest`` backported for Python 2.6 compatibility.
-
- Since Django no longer supports Python versions older than 2.7,
- ``django.utils.unittest`` is deprecated. Simply use ``unittest``.
-
-.. _unittest2: https://pypi.python.org/pypi/unittest2
-
Here is an example which subclasses from :class:`django.test.TestCase`,
which is a subclass of :class:`unittest.TestCase` that runs each test inside a
transaction to provide isolation::
diff --git a/setup.cfg b/setup.cfg
index cc40e0fbde..d816b4c617 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -3,7 +3,7 @@ doc_files = docs extras AUTHORS INSTALL LICENSE README.rst
install-script = scripts/rpm-install.sh
[flake8]
-exclude=build,.git,./django/utils/unittest.py,./django/utils/lru_cache.py,./django/utils/six.py,./django/conf/app_template/*,./django/dispatch/weakref_backports.py,./tests/.env,./xmlrunner,./tests/test_*.py
+exclude=build,.git,./django/utils/lru_cache.py,./django/utils/six.py,./django/conf/app_template/*,./django/dispatch/weakref_backports.py,./tests/.env,./xmlrunner,./tests/test_*.py
ignore=E123,E128,E265,E501,W601
max-line-length = 119
diff --git a/tests/.coveragerc b/tests/.coveragerc
index f32b4d6726..ef4b90d22e 100644
--- a/tests/.coveragerc
+++ b/tests/.coveragerc
@@ -1,5 +1,5 @@
[run]
-omit = */django/contrib/*/tests*,*/django/utils/unittest*,*/django/core/servers/fastcgi.py,*/django/utils/autoreload.py
+omit = */django/contrib/*/tests*,*/django/core/servers/fastcgi.py,*/django/utils/autoreload.py
[report]
ignore_errors = True