diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-06-17 09:34:12 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-06-17 09:34:12 +0000 |
commit | b93e040bb897d25603aca5eba26961dfa84946a9 (patch) | |
tree | 511342aaf94b24fc0fef4e0c110523dd550eda18 | |
parent | dbdc9b9da7564eafd9d74aa9d664642193d9791d (diff) | |
download | redmine-b93e040bb897d25603aca5eba26961dfa84946a9.tar.gz redmine-b93e040bb897d25603aca5eba26961dfa84946a9.zip |
fix unit test fails on Ruby 1.8 and JRuby (#2190)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9850 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | test/unit/lib/redmine/i18n_test.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/unit/lib/redmine/i18n_test.rb b/test/unit/lib/redmine/i18n_test.rb index 85d9a1312..2ec6dc2f9 100644 --- a/test/unit/lib/redmine/i18n_test.rb +++ b/test/unit/lib/redmine/i18n_test.rb @@ -44,7 +44,9 @@ class Redmine::I18nTest < ActiveSupport::TestCase today = now = Time.parse('2011-02-20 14:00:00') Setting.date_format = '%d %B %Y' User.current.language = 'fr' - assert_equal "20 f\u00E9vrier 2011", format_date(today) + s1 = "20 f\xc3\xa9vrier 2011" + s1.force_encoding("UTF-8") if s1.respond_to?(:force_encoding) + assert_equal s1, format_date(today) User.current.language = nil assert_equal '20 Febrero 2011', format_date(today) end |