From: Toshi MARUYAMA Date: Tue, 8 Mar 2011 07:41:04 +0000 (+0000) Subject: scm: git: prepare path encoding test in unit model test (#5251). X-Git-Tag: 1.2.0~785 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7d47bf8a7f27c8cea9e4556435c75deed48e0269;p=redmine.git scm: git: prepare path encoding test in unit model test (#5251). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5057 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/test/unit/repository_git_test.rb b/test/unit/repository_git_test.rb index 0c2f6a3c8..a39b1ff73 100644 --- a/test/unit/repository_git_test.rb +++ b/test/unit/repository_git_test.rb @@ -25,6 +25,7 @@ class RepositoryGitTest < ActiveSupport::TestCase REPOSITORY_PATH.gsub!(/\//, "\\") if Redmine::Platform.mswin? FELIX_HEX = "Felix Sch\xC3\xA4fer" + CHAR_1_HEX = "\xc3\x9c" def setup @project = Project.find(3) @@ -34,6 +35,10 @@ class RepositoryGitTest < ActiveSupport::TestCase :path_encoding => 'ISO-8859-1' ) assert @repository + @char_1 = CHAR_1_HEX.dup + if @char_1.respond_to?(:force_encoding) + @char_1.force_encoding('UTF-8') + end end if File.directory?(REPOSITORY_PATH)