From ee3cf64d52840ac05dd2f903de4f7ab6b856920c Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Thu, 12 May 2011 23:45:04 +0000 Subject: [PATCH] scm: git: add test of revisions() with invalid revision in unit adapter test (#7146). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5764 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- test/unit/lib/redmine/scm/adapters/git_adapter_test.rb | 9 +++++++++ 1 file changed, 9 insertions(+) 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 8274e8b1d..6b9c158d0 100644 --- a/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb +++ b/test/unit/lib/redmine/scm/adapters/git_adapter_test.rb @@ -163,6 +163,15 @@ begin assert_equal '1ca7f5ed374f3cb31a93ae5215c2e25cc6ec5127', revs2[-1].identifier end + def test_revisions_invalid_rev + revs1 = nil + revs1 = @adapter.revisions('', + '1234abcd', + "master", + {:reverse => true}) + assert_equal [], revs1 + end + def test_getting_revisions_with_spaces_in_filename assert_equal 1, @adapter.revisions("filemane with spaces.txt", nil, nil, :all => true).length -- 2.39.5