diff options
author | Eric Davis <edavis@littlestreamsoftware.com> | 2010-04-21 16:02:55 +0000 |
---|---|---|
committer | Eric Davis <edavis@littlestreamsoftware.com> | 2010-04-21 16:02:55 +0000 |
commit | 9b595c689d06ffc1386e242177358711bdbf5c3a (patch) | |
tree | 50b51d5cf708fe43aa2b3dce4d56ea871b3e1319 /test/functional/documents_controller_test.rb | |
parent | 0fc884cf422356a2b57131daaa3340fd9da91b46 (diff) | |
download | redmine-9b595c689d06ffc1386e242177358711bdbf5c3a.tar.gz redmine-9b595c689d06ffc1386e242177358711bdbf5c3a.zip |
Refactor: Move the rest of the routing tests to RoutingTest.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3687 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/documents_controller_test.rb')
-rw-r--r-- | test/functional/documents_controller_test.rb | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/test/functional/documents_controller_test.rb b/test/functional/documents_controller_test.rb index bdab5ac1a..65afc229c 100644 --- a/test/functional/documents_controller_test.rb +++ b/test/functional/documents_controller_test.rb @@ -31,13 +31,6 @@ class DocumentsControllerTest < ActionController::TestCase User.current = nil end - def test_index_routing - assert_routing( - {:method => :get, :path => '/projects/567/documents'}, - :controller => 'documents', :action => 'index', :project_id => '567' - ) - end - def test_index # Sets a default category e = Enumeration.find_by_name('Technical documentation') @@ -54,17 +47,6 @@ class DocumentsControllerTest < ActionController::TestCase :content => 'Technical documentation'} end - def test_new_routing - assert_routing( - {:method => :get, :path => '/projects/567/documents/new'}, - :controller => 'documents', :action => 'new', :project_id => '567' - ) - assert_recognizes( - {:controller => 'documents', :action => 'new', :project_id => '567'}, - {:method => :post, :path => '/projects/567/documents'} - ) - end - def test_new_with_one_attachment ActionMailer::Base.deliveries.clear Setting.notified_events << 'document_added' @@ -87,31 +69,6 @@ class DocumentsControllerTest < ActionController::TestCase assert_equal 1, ActionMailer::Base.deliveries.size end - def test_edit_routing - assert_routing( - {:method => :get, :path => '/documents/22/edit'}, - :controller => 'documents', :action => 'edit', :id => '22' - ) - assert_recognizes(#TODO: should be using PUT on document URI - {:controller => 'documents', :action => 'edit', :id => '567'}, - {:method => :post, :path => '/documents/567/edit'} - ) - end - - def test_show_routing - assert_routing( - {:method => :get, :path => '/documents/22'}, - :controller => 'documents', :action => 'show', :id => '22' - ) - end - - def test_destroy_routing - assert_recognizes(#TODO: should be using DELETE on document URI - {:controller => 'documents', :action => 'destroy', :id => '567'}, - {:method => :post, :path => '/documents/567/destroy'} - ) - end - def test_destroy @request.session[:user_id] = 2 post :destroy, :id => 1 |