diff options
author | Anssi Kääriäinen <akaariai@gmail.com> | 2013-08-07 09:51:32 +0300 |
---|---|---|
committer | Anssi Kääriäinen <akaariai@gmail.com> | 2013-08-19 09:51:28 +0300 |
commit | 4668c142dce77c6f29fb75532c1acfa1b2d322ff (patch) | |
tree | 0d4bfb51d43879c9e0410e42152542a3c78e828d /tests/proxy_models | |
parent | 40909826172374b849ddc9db8e1a8be9a8c3251b (diff) | |
download | django-4668c142dce77c6f29fb75532c1acfa1b2d322ff.tar.gz |
Made Model.__eq__ consider proxy models equivalent
Fixed #11892, fixed #16458, fixed #14492.
Diffstat (limited to 'tests/proxy_models')
-rw-r--r-- | tests/proxy_models/tests.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/proxy_models/tests.py b/tests/proxy_models/tests.py index 240198cc39..3598d65935 100644 --- a/tests/proxy_models/tests.py +++ b/tests/proxy_models/tests.py @@ -362,6 +362,9 @@ class ProxyModelTests(TestCase): p = MyPerson.objects.get(pk=100) self.assertEqual(p.name, 'Elvis Presley') + def test_eq(self): + self.assertEqual(MyPerson(id=100), Person(id=100)) + class ProxyModelAdminTests(TestCase): fixtures = ['myhorses'] |