summaryrefslogtreecommitdiff
path: root/tests/null_queries
diff options
context:
space:
mode:
authorFlavio Curella <flavio.curella@gmail.com>2015-07-22 09:43:21 -0500
committerTim Graham <timograham@gmail.com>2015-07-27 18:28:13 -0400
commitc2e70f02653519db3a49cd48f5158ccad7434d25 (patch)
treec0f421a6b0c26a7716c380b3e360fecc74d553fb /tests/null_queries
parent87d55081ea398c65b2503d22ed3907a9175ec729 (diff)
Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField
Diffstat (limited to 'tests/null_queries')
-rw-r--r--tests/null_queries/models.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/null_queries/models.py b/tests/null_queries/models.py
index 1c3808f407..8d915ba11f 100644
--- a/tests/null_queries/models.py
+++ b/tests/null_queries/models.py
@@ -14,7 +14,7 @@ class Poll(models.Model):
@python_2_unicode_compatible
class Choice(models.Model):
- poll = models.ForeignKey(Poll)
+ poll = models.ForeignKey(Poll, models.CASCADE)
choice = models.CharField(max_length=200)
def __str__(self):
@@ -32,6 +32,6 @@ class OuterB(models.Model):
class Inner(models.Model):
- first = models.ForeignKey(OuterA)
+ first = models.ForeignKey(OuterA, models.CASCADE)
# second would clash with the __second lookup.
- third = models.ForeignKey(OuterB, null=True)
+ third = models.ForeignKey(OuterB, models.SET_NULL, null=True)