diff --git a/test/integration/repositories_git_test.rb b/test/integration/repositories_git_test.rb index 5c54d1e2f..8c13b63c8 100644 --- a/test/integration/repositories_git_test.rb +++ b/test/integration/repositories_git_test.rb @@ -82,14 +82,18 @@ class RepositoriesGitTest < Redmine::IntegrationTest @repository.fetch_changesets assert_equal NUM_REV, @repository.changesets.count - get "/projects/subproject1/repository/#{@repository.id}/revisions/deff712f05a90d96edbd70facc47d944be5897e3/diff/sources/watchers_controller.rb", :params => { :format => 'txt' } + id = "deff712f05a90d96edbd70facc47d944be5897e3" + get( + "/projects/subproject1/repository/#{@repository.id}/revisions/#{id}/diff/sources/watchers_controller.rb", + :params => {:format => 'txt'} + ) assert_response :success assert a = css_select("a.diff").first assert_equal 'Unified diff', a.text get a['href'] assert_response :success - assert_match /\Acommit deff712f05a90d96edbd70facc47d944be5897e3/, response.body + assert_match /\Acommit #{id}/, response.body end def test_entry_txt_should_return_html