@@ -170,6 +170,15 class RepositoriesGitControllerTest < ActionController::TestCase | |||
|
170 | 170 | :sibling => { :tag => 'td', :content => /watcher =/ } |
|
171 | 171 | end |
|
172 | 172 | |
|
173 | def test_annotate_at_given_revision | |
|
174 | @repository.fetch_changesets | |
|
175 | @repository.reload | |
|
176 | get :annotate, :id => 3, :rev => 'deff7', :path => ['sources', 'watchers_controller.rb'] | |
|
177 | assert_response :success | |
|
178 | assert_template 'annotate' | |
|
179 | assert_tag :tag => 'h2', :content => /@ deff712f/ | |
|
180 | end | |
|
181 | ||
|
173 | 182 | def test_annotate_binary_file |
|
174 | 183 | get :annotate, :id => 3, :path => ['images', 'edit.png'] |
|
175 | 184 | assert_response 500 |
@@ -196,6 +196,17 class RepositoriesMercurialControllerTest < ActionController::TestCase | |||
|
196 | 196 | :sibling => { :tag => 'td', :content => /watcher =/ } |
|
197 | 197 | end |
|
198 | 198 | |
|
199 | def test_annotate_at_given_revision | |
|
200 | @repository.fetch_changesets | |
|
201 | @repository.reload | |
|
202 | [2, '400bb8672109', '400', 400].each do |r1| | |
|
203 | get :annotate, :id => 3, :rev => r1, :path => ['sources', 'watchers_controller.rb'] | |
|
204 | assert_response :success | |
|
205 | assert_template 'annotate' | |
|
206 | assert_tag :tag => 'h2', :content => /@ 2:400bb8672109/ | |
|
207 | end | |
|
208 | end | |
|
209 | ||
|
199 | 210 | def test_empty_revision |
|
200 | 211 | @repository.fetch_changesets |
|
201 | 212 | @repository.reload |
@@ -228,6 +228,13 class RepositoriesSubversionControllerTest < ActionController::TestCase | |||
|
228 | 228 | assert_response :success |
|
229 | 229 | assert_template 'annotate' |
|
230 | 230 | end |
|
231 | ||
|
232 | def test_annotate_at_given_revision | |
|
233 | get :annotate, :id => 1, :rev => 8, :path => ['subversion_test', 'helloworld.c'] | |
|
234 | assert_response :success | |
|
235 | assert_template 'annotate' | |
|
236 | assert_tag :tag => 'h2', :content => /@ 8/ | |
|
237 | end | |
|
231 | 238 | else |
|
232 | 239 | puts "Subversion test repository NOT FOUND. Skipping functional tests !!!" |
|
233 | 240 | def test_fake; assert true end |
General Comments 0
You need to be logged in to leave comments.
Login now