summaryrefslogtreecommitdiffstats
path: root/test/unit/wiki_test.rb
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-03-14 01:16:05 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-03-14 01:16:05 +0000
commit224331dacb9e376a5e3a779276007d000b8e58ed (patch)
tree15e6f387b28bc93df9c2e13bf4faf6e7dd26485d /test/unit/wiki_test.rb
parentae5edac2438da84e2673b0721ec0aea448d5fea2 (diff)
downloadredmine-224331dacb9e376a5e3a779276007d000b8e58ed.tar.gz
redmine-224331dacb9e376a5e3a779276007d000b8e58ed.zip
replace hard-coded non ASCII literal to UTF-8 hexadecimal at test/unit/wiki_test.rb
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9239 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/wiki_test.rb')
-rw-r--r--test/unit/wiki_test.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/unit/wiki_test.rb b/test/unit/wiki_test.rb
index 923ff528e..4b6f817ed 100644
--- a/test/unit/wiki_test.rb
+++ b/test/unit/wiki_test.rb
@@ -78,8 +78,10 @@ class WikiTest < ActiveSupport::TestCase
end
def test_titleize
+ ja_test = "\xe3\x83\x86\xe3\x82\xb9\xe3\x83\x88"
+ ja_test.force_encoding('UTF-8') if ja_test.respond_to?(:force_encoding)
assert_equal 'Page_title_with_CAPITALES', Wiki.titleize('page title with CAPITALES')
- assert_equal 'テスト', Wiki.titleize('テスト')
+ assert_equal ja_test, Wiki.titleize(ja_test)
end
context "#sidebar" do