mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Fixed #26998 -- Reverted some admin checks from checking field.many_to_many back to isinstance(field, models.ManyToManyField).
This partially reverts 983c158da7
This commit is contained in:
committed by
Tim Graham
parent
a3db480393
commit
384f89f8f8
@@ -925,7 +925,7 @@ class PrepopulatedFieldsCheckTests(CheckTestCase):
|
||||
self.assertIsInvalid(
|
||||
ValidationTestModelAdmin, ValidationTestModel,
|
||||
("The value of 'prepopulated_fields' refers to 'users', which must not be "
|
||||
"a DateTimeField, a foreign key, or a many-to-many field."),
|
||||
"a DateTimeField, a ForeignKey, or a ManyToManyField."),
|
||||
'admin.E028')
|
||||
|
||||
def test_valid_case(self):
|
||||
@@ -963,7 +963,7 @@ class ListDisplayTests(CheckTestCase):
|
||||
|
||||
self.assertIsInvalid(
|
||||
ValidationTestModelAdmin, ValidationTestModel,
|
||||
"The value of 'list_display[0]' must not be a many-to-many field.",
|
||||
"The value of 'list_display[0]' must not be a ManyToManyField.",
|
||||
'admin.E109')
|
||||
|
||||
def test_valid_case(self):
|
||||
|
||||
Reference in New Issue
Block a user