From a2eaea8f22305b57dff3ab13add2e2887287bb6f Mon Sep 17 00:00:00 2001 From: "T. Franzel" Date: Sat, 11 Mar 2023 00:34:13 +0100 Subject: Fixed #34388 -- Allowed using choice enumeration types directly on model and form fields. --- tests/model_fields/test_integerfield.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/model_fields/test_integerfield.py') diff --git a/tests/model_fields/test_integerfield.py b/tests/model_fields/test_integerfield.py index 7698160678..6761589b7e 100644 --- a/tests/model_fields/test_integerfield.py +++ b/tests/model_fields/test_integerfield.py @@ -301,11 +301,11 @@ class ValidationTests(SimpleTestCase): f.clean("0", None) def test_enum_choices_cleans_valid_string(self): - f = models.IntegerField(choices=self.Choices.choices) + f = models.IntegerField(choices=self.Choices) self.assertEqual(f.clean("1", None), 1) def test_enum_choices_invalid_input(self): - f = models.IntegerField(choices=self.Choices.choices) + f = models.IntegerField(choices=self.Choices) with self.assertRaises(ValidationError): f.clean("A", None) with self.assertRaises(ValidationError): -- cgit v1.3