@@ -146,4 +146,15 class Redmine::I18nTest < ActiveSupport::TestCase | |||||
146 | ::I18n.locale = 'fr' |
|
146 | ::I18n.locale = 'fr' | |
147 | assert_equal "Pas de traduction", l(:untranslated) |
|
147 | assert_equal "Pas de traduction", l(:untranslated) | |
148 | end |
|
148 | end | |
|
149 | ||||
|
150 | def test_utf8 | |||
|
151 | set_language_if_valid 'ja' | |||
|
152 | str_ja_yes = "\xe3\x81\xaf\xe3\x81\x84" | |||
|
153 | i18n_ja_yes = l(:general_text_Yes) | |||
|
154 | if str_ja_yes.respond_to?(:force_encoding) | |||
|
155 | str_ja_yes.force_encoding('UTF-8') | |||
|
156 | assert_equal "UTF-8", i18n_ja_yes.encoding.to_s | |||
|
157 | end | |||
|
158 | assert_equal str_ja_yes, i18n_ja_yes | |||
|
159 | end | |||
149 | end |
|
160 | end |
General Comments 0
You need to be logged in to leave comments.
Login now