diff options
| author | Tim Graham <timograham@gmail.com> | 2017-12-07 09:05:36 -0500 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2017-12-07 09:06:09 -0500 |
| commit | a06828cd2e3e34188466ed4f9a76d7838d0bf4f5 (patch) | |
| tree | 9692e4a00ae1ed30c514b2226fee64a5a9343f6d /tests | |
| parent | 6b01ff80b21bb7e159fceb4af36077e536706487 (diff) | |
[2.0.x] Reverted "[1.11.x] Refs #28856 -- Fixed caching of a GenericForeignKey pointing to a model that uses more than one level of MTI."
This reverts commit a2aea4521d5e3cf8c76ef17e6edafee1c87bbf0a as it was
committed by mistake.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/generic_relations_regress/models.py | 5 | ||||
| -rw-r--r-- | tests/generic_relations_regress/tests.py | 12 |
2 files changed, 3 insertions, 14 deletions
diff --git a/tests/generic_relations_regress/models.py b/tests/generic_relations_regress/models.py index c9572eb961..2011ea14b9 100644 --- a/tests/generic_relations_regress/models.py +++ b/tests/generic_relations_regress/models.py @@ -38,11 +38,6 @@ class Restaurant(Place): return "Restaurant: %s" % self.name -class Cafe(Restaurant): - def __str__(self): - return "Cafe: %s" % self.name - - class Address(models.Model): street = models.CharField(max_length=80) city = models.CharField(max_length=50) diff --git a/tests/generic_relations_regress/tests.py b/tests/generic_relations_regress/tests.py index f052cb61df..cfac484053 100644 --- a/tests/generic_relations_regress/tests.py +++ b/tests/generic_relations_regress/tests.py @@ -5,10 +5,9 @@ from django.forms.models import modelform_factory from django.test import TestCase, skipIfDBFeature from .models import ( - A, Address, B, Board, C, Cafe, CharLink, Company, Contact, Content, D, - Developer, Guild, HasLinkThing, Link, Node, Note, OddRelation1, - OddRelation2, Organization, Person, Place, Related, Restaurant, Tag, Team, - TextLink, + A, Address, B, Board, C, CharLink, Company, Contact, Content, D, Developer, + Guild, HasLinkThing, Link, Node, Note, OddRelation1, OddRelation2, + Organization, Person, Place, Related, Restaurant, Tag, Team, TextLink, ) @@ -55,11 +54,6 @@ class GenericRelationTests(TestCase): charlink = CharLink.objects.latest('pk') self.assertIs(charlink.content_object, charlink.content_object) - cafe = Cafe.objects.create() - CharLink.objects.create(content_object=cafe) - charlink = CharLink.objects.latest('pk') - self.assertIs(charlink.content_object, charlink.content_object) - def test_q_object_or(self): """ SQL query parameters for generic relations are properly |
