diff options
Diffstat (limited to 'tests/modeladmin/tests.py')
| -rw-r--r-- | tests/modeladmin/tests.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/tests/modeladmin/tests.py b/tests/modeladmin/tests.py index ee8c26c3ca..6157d6c1d4 100644 --- a/tests/modeladmin/tests.py +++ b/tests/modeladmin/tests.py @@ -7,16 +7,13 @@ from django.contrib.admin.options import (ModelAdmin, TabularInline, HORIZONTAL, VERTICAL) from django.contrib.admin.sites import AdminSite from django.contrib.admin.widgets import AdminDateWidget, AdminRadioSelect -from django.contrib.admin.validation import ModelAdminValidator from django.contrib.admin import (SimpleListFilter, BooleanFieldListFilter) from django.core.checks import Error -from django.core.exceptions import ImproperlyConfigured from django.forms.models import BaseModelFormSet from django.forms.widgets import Select -from django.test import TestCase, ignore_warnings +from django.test import TestCase from django.utils import six -from django.utils.deprecation import RemovedInDjango19Warning from .models import Band, Concert, ValidationTestModel, ValidationTestInlineModel @@ -1503,21 +1500,6 @@ class FormsetCheckTests(CheckTestCase): self.assertIsValid(ValidationTestModelAdmin, ValidationTestModel) -class CustomModelAdminTests(CheckTestCase): - @ignore_warnings(category=RemovedInDjango19Warning) - def test_deprecation(self): - "Deprecated Custom Validator definitions still work with the check framework." - - class CustomValidator(ModelAdminValidator): - def validate_me(self, model_admin, model): - raise ImproperlyConfigured('error!') - - class CustomModelAdmin(ModelAdmin): - validator_class = CustomValidator - - self.assertIsInvalid(CustomModelAdmin, ValidationTestModel, 'error!') - - class ListDisplayEditableTests(CheckTestCase): def test_list_display_links_is_none(self): """ |
