@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