mirror of
https://github.com/redmine/redmine.git
synced 2025-11-07 22:05:56 +01:00
fix source indent of GitAdapterTest
git-svn-id: http://svn.redmine.org/redmine/trunk@20540 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -240,13 +240,13 @@ class GitAdapterTest < ActiveSupport::TestCase
|
||||
else
|
||||
revs1 = []
|
||||
@adapter.revisions(
|
||||
'',
|
||||
"latin-1-branch-#{@char_1}-01",
|
||||
"latin-1-branch-#{@char_1}-02",
|
||||
{:reverse => true}) do |rev|
|
||||
'',
|
||||
"latin-1-branch-#{@char_1}-01",
|
||||
"latin-1-branch-#{@char_1}-02",
|
||||
{:reverse => true}
|
||||
) do |rev|
|
||||
revs1 << rev
|
||||
end
|
||||
|
||||
assert_equal 2, revs1.length
|
||||
assert_equal '64f1f3e89ad1cb57976ff0ad99a107012ba3481d', revs1[0].identifier
|
||||
assert_equal '1ca7f5ed374f3cb31a93ae5215c2e25cc6ec5127', revs1[1].identifier
|
||||
@@ -258,10 +258,11 @@ class GitAdapterTest < ActiveSupport::TestCase
|
||||
assert_raise Redmine::Scm::Adapters::CommandFailed do
|
||||
revs1 = []
|
||||
@adapter.revisions(
|
||||
'',
|
||||
'1234abcd',
|
||||
"master",
|
||||
{:reverse => true}) do |rev|
|
||||
'',
|
||||
'1234abcd',
|
||||
"master",
|
||||
{:reverse => true}
|
||||
) do |rev|
|
||||
revs1 << rev
|
||||
end
|
||||
end
|
||||
@@ -392,17 +393,20 @@ class GitAdapterTest < ActiveSupport::TestCase
|
||||
|
||||
def test_getting_revisions_with_leading_and_trailing_spaces_in_filename
|
||||
assert_equal(
|
||||
" filename with a leading space.txt ",
|
||||
@adapter.revisions(" filename with a leading space.txt ",
|
||||
nil, "master")[0].paths[0][:path])
|
||||
" filename with a leading space.txt ",
|
||||
@adapter.revisions(" filename with a leading space.txt ",
|
||||
nil, "master")[0].paths[0][:path]
|
||||
)
|
||||
end
|
||||
|
||||
def test_getting_entries_with_leading_and_trailing_spaces_in_filename
|
||||
assert_equal(
|
||||
" filename with a leading space.txt ",
|
||||
@adapter.entries(
|
||||
'',
|
||||
'83ca5fd546063a3c7dc2e568ba3355661a9e2b2c')[3].name)
|
||||
" filename with a leading space.txt ",
|
||||
@adapter.entries(
|
||||
'',
|
||||
'83ca5fd546063a3c7dc2e568ba3355661a9e2b2c'
|
||||
)[3].name
|
||||
)
|
||||
end
|
||||
|
||||
def test_annotate
|
||||
@@ -618,17 +622,19 @@ class GitAdapterTest < ActiveSupport::TestCase
|
||||
end
|
||||
|
||||
def test_path_encoding_default_utf8
|
||||
adpt1 = Redmine::Scm::Adapters::GitAdapter.new(
|
||||
REPOSITORY_PATH
|
||||
)
|
||||
adpt1 =
|
||||
Redmine::Scm::Adapters::GitAdapter.new(
|
||||
REPOSITORY_PATH
|
||||
)
|
||||
assert_equal "UTF-8", adpt1.path_encoding
|
||||
adpt2 = Redmine::Scm::Adapters::GitAdapter.new(
|
||||
REPOSITORY_PATH,
|
||||
nil,
|
||||
nil,
|
||||
nil,
|
||||
""
|
||||
)
|
||||
adpt2 =
|
||||
Redmine::Scm::Adapters::GitAdapter.new(
|
||||
REPOSITORY_PATH,
|
||||
nil,
|
||||
nil,
|
||||
nil,
|
||||
""
|
||||
)
|
||||
assert_equal "UTF-8", adpt2.path_encoding
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user