Skip to content

Commit

Permalink
Removed RemovedInDjango110Warning.
Browse files Browse the repository at this point in the history
  • Loading branch information
timgraham committed Sep 23, 2015
1 parent 2ccfac1 commit 48e7787
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 11 deletions.
6 changes: 1 addition & 5 deletions django/utils/deprecation.py
Expand Up @@ -8,11 +8,7 @@ class RemovedInDjango20Warning(PendingDeprecationWarning):
pass


class RemovedInDjango110Warning(DeprecationWarning):
pass


RemovedInNextVersionWarning = RemovedInDjango110Warning
RemovedInNextVersionWarning = DeprecationWarning


class warn_about_renamed_method(object):
Expand Down
5 changes: 1 addition & 4 deletions tests/runtests.py
Expand Up @@ -19,12 +19,9 @@
from django.test.utils import get_runner
from django.utils import six
from django.utils._os import upath
from django.utils.deprecation import (
RemovedInDjango20Warning, RemovedInDjango110Warning,
)
from django.utils.deprecation import RemovedInDjango20Warning
from django.utils.log import DEFAULT_LOGGING

warnings.simplefilter("error", RemovedInDjango110Warning)
warnings.simplefilter("error", RemovedInDjango20Warning)

RUNTESTS_DIR = os.path.abspath(os.path.dirname(upath(__file__)))
Expand Down
5 changes: 3 additions & 2 deletions tests/test_runner/tests.py
Expand Up @@ -352,8 +352,9 @@ def test_runner_deprecation_verbosity_default(self):
args = ['test', '--settings=test_project.settings', 'test_runner_deprecation_app']
out, err = self.run_django_admin(args)
self.assertIn("Ran 1 test", force_text(err))
six.assertRegex(self, err, r"RemovedInDjango\d+Warning: warning from test")
six.assertRegex(self, err, r"RemovedInDjango\d+Warning: module-level warning from deprecation_app")
# change "Deprecation" to "RemovedInDjango\d+" in Django 1.11.
six.assertRegex(self, err, r"DeprecationWarning: warning from test")
six.assertRegex(self, err, r"DeprecationWarning: module-level warning from deprecation_app")

def test_runner_deprecation_verbosity_zero(self):
args = ['test', '--settings=test_project.settings', '--verbosity=0', 'test_runner_deprecation_app']
Expand Down

0 comments on commit 48e7787

Please sign in to comment.