mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Added app labels to related fields checks messages E302-E305.
This commit is contained in:
parent
72d04e0385
commit
45519937e5
4 changed files with 222 additions and 111 deletions
|
@ -225,19 +225,24 @@ class AbstractInheritanceTests(SimpleTestCase):
|
|||
Foo._meta.get_field('foo').check(),
|
||||
[
|
||||
Error(
|
||||
"Reverse accessor for 'Foo.foo' clashes with field name 'Descendant.foo'.",
|
||||
"Reverse accessor for 'model_inheritance.Foo.foo' clashes "
|
||||
"with field name 'model_inheritance.Descendant.foo'.",
|
||||
hint=(
|
||||
"Rename field 'Descendant.foo', or add/change a related_name "
|
||||
"argument to the definition for field 'Foo.foo'."
|
||||
"Rename field 'model_inheritance.Descendant.foo', or "
|
||||
"add/change a related_name argument to the definition "
|
||||
"for field 'model_inheritance.Foo.foo'."
|
||||
),
|
||||
obj=Foo._meta.get_field('foo'),
|
||||
id='fields.E302',
|
||||
),
|
||||
Error(
|
||||
"Reverse query name for 'Foo.foo' clashes with field name 'Descendant.foo'.",
|
||||
"Reverse query name for 'model_inheritance.Foo.foo' "
|
||||
"clashes with field name "
|
||||
"'model_inheritance.Descendant.foo'.",
|
||||
hint=(
|
||||
"Rename field 'Descendant.foo', or add/change a related_name "
|
||||
"argument to the definition for field 'Foo.foo'."
|
||||
"Rename field 'model_inheritance.Descendant.foo', or "
|
||||
"add/change a related_name argument to the definition "
|
||||
"for field 'model_inheritance.Foo.foo'."
|
||||
),
|
||||
obj=Foo._meta.get_field('foo'),
|
||||
id='fields.E303',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue