summaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2013-09-18 06:16:43 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2013-09-18 06:16:43 +0000
commitda87e4b1ef39e03a59a00e3cf8de2b0ad351f5c8 (patch)
tree2f730dfdc534092c26db285f5f6bf34ef510cb9a /test/unit
parenteaf05a87b4759ec9ceb9e7b7620cd7c0cdc6eb72 (diff)
downloadredmine-da87e4b1ef39e03a59a00e3cf8de2b0ad351f5c8.tar.gz
redmine-da87e4b1ef39e03a59a00e3cf8de2b0ad351f5c8.zip
scm: git: change non ASCII user name variable to instance variable (#14931)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@12142 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/lib/redmine/scm/adapters/git_adapter_test.rb8
1 files changed, 3 insertions, 5 deletions
diff --git a/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb b/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb
index 420d411c5..7155bed4f 100644
--- a/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb
+++ b/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb
@@ -61,8 +61,10 @@ begin
)
assert @adapter
@char_1 = CHAR_1_HEX.dup
+ @str_felix_hex = FELIX_HEX.dup
if @char_1.respond_to?(:force_encoding)
@char_1.force_encoding('UTF-8')
+ @str_felix_hex.force_encoding('ASCII-8BIT')
end
end
@@ -396,14 +398,10 @@ begin
def test_last_rev_with_spaces_in_filename
last_rev = @adapter.lastrev("filemane with spaces.txt",
"ed5bb786bbda2dee66a2d50faf51429dbc043a7b")
- str_felix_hex = FELIX_HEX.dup
last_rev_author = last_rev.author
- if last_rev_author.respond_to?(:force_encoding)
- str_felix_hex.force_encoding('ASCII-8BIT')
- end
assert_equal "ed5bb786bbda2dee66a2d50faf51429dbc043a7b", last_rev.scmid
assert_equal "ed5bb786bbda2dee66a2d50faf51429dbc043a7b", last_rev.identifier
- assert_equal "#{str_felix_hex} <felix@fachschaften.org>",
+ assert_equal "#{@str_felix_hex} <felix@fachschaften.org>",
last_rev.author
assert_equal "2010-09-18 19:59:46".to_time, last_rev.time
end