From: Toshi MARUYAMA Date: Mon, 3 Jan 2011 10:45:44 +0000 (+0000) Subject: repository: mercurial: fix functional annotate test. X-Git-Tag: 1.2.0~1138 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=5e1c42cbe3b0d3b5d6825870b3d99c18bc6060ef;p=redmine.git repository: mercurial: fix functional annotate test. Mercurial test repository author is 'jsmith'. If author is 'foo', functional annotate test passes. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4625 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/test/functional/repositories_mercurial_controller_test.rb b/test/functional/repositories_mercurial_controller_test.rb index a37acfa18..d8f29ec8b 100644 --- a/test/functional/repositories_mercurial_controller_test.rb +++ b/test/functional/repositories_mercurial_controller_test.rb @@ -125,10 +125,29 @@ class RepositoriesMercurialControllerTest < ActionController::TestCase get :annotate, :id => 3, :path => ['sources', 'watchers_controller.rb'] assert_response :success assert_template 'annotate' - # Line 23, revision 4 - assert_tag :tag => 'th', :content => /23/, - :sibling => { :tag => 'td', :child => { :tag => 'a', :content => /4/ } }, - :sibling => { :tag => 'td', :content => /jsmith/ }, + # Line 23, revision 4:def6d2f1254a + assert_tag :tag => 'th', + :content => '23', + :attributes => { :class => 'line-num' }, + :sibling => + { + :tag => 'td', + :attributes => { :class => 'revision' }, + :child => { :tag => 'a', :content => '4' } + # :child => { :tag => 'a', :content => /4:def6d2f1/ } + } + assert_tag :tag => 'th', + :content => '23', + :attributes => { :class => 'line-num' }, + :sibling => + { + :tag => 'td' , + :content => 'jsmith' , + :attributes => { :class => 'author' }, + } + assert_tag :tag => 'th', + :content => '23', + :attributes => { :class => 'line-num' }, :sibling => { :tag => 'td', :content => /watcher =/ } end else