From 67bc2f1b9917baec0aeb9e2596454d127178eeff Mon Sep 17 00:00:00 2001 From: Msvstl <59284206+sridhar562345@users.noreply.github.com> Date: Sat, 29 Oct 2022 16:57:10 +0530 Subject: [PATCH] Corrected test_update_or_create_with_model_property_defaults test. --- AUTHORS | 1 + tests/get_or_create/tests.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/AUTHORS b/AUTHORS index dd45f1bd8c..6359e50154 100644 --- a/AUTHORS +++ b/AUTHORS @@ -901,6 +901,7 @@ answer newbie questions, and generally made Django that much better: smurf@smurf.noris.de sopel Sreehari K V + Sridhar Marella Srinivas Reddy Thatiparthy Stanislas Guerra Stanislaus Madueke diff --git a/tests/get_or_create/tests.py b/tests/get_or_create/tests.py index 65d7510682..c3de4ae180 100644 --- a/tests/get_or_create/tests.py +++ b/tests/get_or_create/tests.py @@ -367,7 +367,7 @@ class UpdateOrCreateTests(TestCase): def test_update_or_create_with_model_property_defaults(self): """Using a property with a setter implemented is allowed.""" - t, _ = Thing.objects.get_or_create( + t, _ = Thing.objects.update_or_create( defaults={"capitalized_name_property": "annie"}, pk=1 ) self.assertEqual(t.name, "Annie")