scm: git: use explicit "master" for latest_changesets at unit app test

If revision is not set, controller sets default branch for latest_changesets.
"git log" returns HEAD on bare repository if revision is not set.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8810 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2012-02-07 23:27:51 +00:00
parent 1489623584
commit ed8f988a9b
1 changed files with 2 additions and 2 deletions

View File

@ -250,11 +250,11 @@ class RepositoryGitTest < ActiveSupport::TestCase
@project.reload
assert_equal NUM_REV, @repository.changesets.count
# with limit
changesets = @repository.latest_changesets('', nil, 2)
changesets = @repository.latest_changesets('', 'master', 2)
assert_equal 2, changesets.size
# with path
changesets = @repository.latest_changesets('images', nil)
changesets = @repository.latest_changesets('images', 'master')
assert_equal [
'deff712f05a90d96edbd70facc47d944be5897e3',
'899a15dba03a3b350b89c3f537e4bbe02a03cdc9',