diff --git a/tests/regressiontests/many_to_one_regress/models.py b/tests/regressiontests/many_to_one_regress/models.py index 57df8f3716..b87b36cb3b 100644 --- a/tests/regressiontests/many_to_one_regress/models.py +++ b/tests/regressiontests/many_to_one_regress/models.py @@ -84,6 +84,16 @@ True >>> p.bestchild is None True +# bestchild should still be None after saving. +>>> p.save() +>>> p.bestchild is None +True + +# bestchild should still be None after fetching the object again. +>>> p = Parent.objects.get(name="Parent") +>>> p.bestchild is None +True + # Assigning None fails: Child.parent is null=False. >>> c.parent = None Traceback (most recent call last):