From f92ac845a9c75992120a5b5b219e607c19d3f0aa Mon Sep 17 00:00:00 2001 From: SaJH Date: Wed, 8 May 2024 22:41:33 +0900 Subject: Fixed #35436 -- Fixed displaying Unicode chars in forms.HStoreField. --- tests/postgres_tests/test_hstore.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/postgres_tests') diff --git a/tests/postgres_tests/test_hstore.py b/tests/postgres_tests/test_hstore.py index 2aaad637c6..cac3eb742a 100644 --- a/tests/postgres_tests/test_hstore.py +++ b/tests/postgres_tests/test_hstore.py @@ -410,6 +410,13 @@ class TestFormField(PostgreSQLSimpleTestCase): form_w_hstore = HStoreFormTest({"f1": '{"a": 2}'}, initial={"f1": {"a": 1}}) self.assertTrue(form_w_hstore.has_changed()) + def test_prepare_value(self): + field = forms.HStoreField() + self.assertEqual( + field.prepare_value({"aira_maplayer": "Αρδευτικό δίκτυο"}), + '{"aira_maplayer": "Αρδευτικό δίκτυο"}', + ) + class TestValidator(PostgreSQLSimpleTestCase): def test_simple_valid(self): -- cgit v1.3