summaryrefslogtreecommitdiff
path: root/tests/basic/models.py
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2015-11-20 10:31:33 -0500
committerTim Graham <timograham@gmail.com>2015-11-21 11:30:18 -0500
commit8727dc8e951d0c3f4afc9cc2a5159fb651e5535c (patch)
tree5ef793a177b7c92866525e931d53f8590ef6f55a /tests/basic/models.py
parent0adbac49439d105098d1cd3d4a01bf366cf32ec4 (diff)
[1.9.x] Fixed #25715 -- Fixed Model.refresh_from_db() with ForeignKey w/on_delete=SET_NULL.
Backport of 54e2e688e1cfbdb37dfa5dd3b3ffdf2af12b4423 from master
Diffstat (limited to 'tests/basic/models.py')
-rw-r--r--tests/basic/models.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/basic/models.py b/tests/basic/models.py
index 0e85087d32..91fbe7d648 100644
--- a/tests/basic/models.py
+++ b/tests/basic/models.py
@@ -34,6 +34,7 @@ class SelfRef(models.Model):
null=True, blank=True,
related_name='+',
)
+ article = models.ForeignKey(Article, models.SET_NULL, null=True, blank=True)
def __str__(self):
# This method intentionally doesn't work for all cases - part