Skip to content

Commit

Permalink
scm: git: code clean up functional test.
Browse files Browse the repository at this point in the history
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5119 e93f8b46-1217-0410-a6f0-8f06a7374b81
  • Loading branch information
marutosi committed Mar 14, 2011
1 parent f3822e1 commit 953e8e0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/functional/repositories_git_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def test_show
assert_not_nil assigns(:entries)
assert_not_nil assigns(:changesets)
end

def test_browse_root
get :show, :id => 3
assert_response :success
Expand Down Expand Up @@ -90,7 +90,7 @@ def test_browse_directory
assert_equal 'file', entry.kind
assert_equal 'images/edit.png', entry.path
end

def test_browse_at_given_revision
get :show, :id => 3, :path => ['images'], :rev => '7234cb2750b63f47bff735edc50a1c0a433c2518'
assert_response :success
Expand All @@ -105,7 +105,7 @@ def test_changes
assert_template 'changes'
assert_tag :tag => 'h2', :content => 'edit.png'
end

def test_entry_show
get :entry, :id => 3, :path => ['sources', 'watchers_controller.rb']
assert_response :success
Expand All @@ -116,14 +116,14 @@ def test_entry_show
:attributes => { :class => /line-num/ },
:sibling => { :tag => 'td', :content => /WITHOUT ANY WARRANTY/ }
end

def test_entry_download
get :entry, :id => 3, :path => ['sources', 'watchers_controller.rb'], :format => 'raw'
assert_response :success
# File content
assert @response.body.include?('WITHOUT ANY WARRANTY')
end

def test_directory_entry
get :entry, :id => 3, :path => ['sources']
assert_response :success
Expand Down

0 comments on commit 953e8e0

Please sign in to comment.