summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2007-05-28 13:02:16 +0000
committerMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2007-05-28 13:02:16 +0000
commit4d31b5297bc7866febdbc4a0875878202c6bacd0 (patch)
treec09fbafa4bf837792fded0cf2bf4ae6a5b3672e8 /tests
parent7bb9a8e3ae432cff280d0df0458461ee512998f7 (diff)
Fixed #4403 -- Stopped pushing form error messages (which are unicode strings)
through a __str__ method. git-svn-id: http://code.djangoproject.com/svn/django/branches/unicode@5375 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests')
-rw-r--r--tests/regressiontests/forms/regressions.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/regressiontests/forms/regressions.py b/tests/regressiontests/forms/regressions.py
index 723cad53cd..54b9138b20 100644
--- a/tests/regressiontests/forms/regressions.py
+++ b/tests/regressiontests/forms/regressions.py
@@ -53,6 +53,13 @@ u'\u0448\u0442.'
>>> f.clean('\xd1\x88\xd1\x82.')
u'\u0448\u0442.'
+Translated error messages used to be buggy.
+>>> activate('ru')
+>>> f = SomeForm({})
+>>> f.as_p()
+u'<p><ul class="errorlist"><li>\u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u043f\u043e\u043b\u0435.</li></ul></p>\n<p><label for="id_somechoice_0">\xc5\xf8\xdf:</label> <ul>\n<li><label><input type="radio" id="id_somechoice_0" value="\xc5" name="somechoice" /> En tied\xe4</label></li>\n<li><label><input type="radio" id="id_somechoice_1" value="\xf8" name="somechoice" /> Mies</label></li>\n<li><label><input type="radio" id="id_somechoice_2" value="\xdf" name="somechoice" /> Nainen</label></li>\n</ul></p>'
+>>> deactivate()
+
#######################
# Miscellaneous Tests #
#######################