diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2016-10-01 12:46:29 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2016-10-01 12:46:29 +0000 |
commit | a2bcc9c40eb99b901f2f92b2f4fa1f840583c6b8 (patch) | |
tree | d49d79b7112da8fb8872fedceac4b6261da9a7d2 /test/functional | |
parent | 973c9484b091e7554f8cd78fdb3f640aa364f7ce (diff) | |
download | redmine-a2bcc9c40eb99b901f2f92b2f4fa1f840583c6b8.tar.gz redmine-a2bcc9c40eb99b901f2f92b2f4fa1f840583c6b8.zip |
Rename AttachmentsController#edit and #update to #edit_all and #update_all (#22356).
git-svn-id: http://svn.redmine.org/redmine/trunk@15860 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional')
-rw-r--r-- | test/functional/attachments_controller_test.rb | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/test/functional/attachments_controller_test.rb b/test/functional/attachments_controller_test.rb index 6a44ca40c..665eb1d9d 100644 --- a/test/functional/attachments_controller_test.rb +++ b/test/functional/attachments_controller_test.rb @@ -354,9 +354,9 @@ class AttachmentsControllerTest < Redmine::ControllerTest puts '(ImageMagick convert not available)' end - def test_edit + def test_edit_all @request.session[:user_id] = 2 - get :edit, :object_type => 'issues', :object_id => '2' + get :edit_all, :object_type => 'issues', :object_id => '2' assert_response :success assert_select 'form[action=?]', '/attachments/issues/2' do @@ -371,24 +371,24 @@ class AttachmentsControllerTest < Redmine::ControllerTest end end - def test_edit_invalid_container_class_should_return_404 - get :edit, :object_type => 'nuggets', :object_id => '3' + def test_edit_all_with_invalid_container_class_should_return_404 + get :edit_all, :object_type => 'nuggets', :object_id => '3' assert_response 404 end - def test_edit_invalid_object_should_return_404 - get :edit, :object_type => 'issues', :object_id => '999' + def test_edit_all_with_invalid_object_should_return_404 + get :edit_all, :object_type => 'issues', :object_id => '999' assert_response 404 end - def test_edit_for_object_that_is_not_visible_should_return_403 - get :edit, :object_type => 'issues', :object_id => '4' + def test_edit_all_for_object_that_is_not_visible_should_return_403 + get :edit_all, :object_type => 'issues', :object_id => '4' assert_response 403 end - def test_update + def test_update_all @request.session[:user_id] = 2 - patch :update, :object_type => 'issues', :object_id => '2', :attachments => { + patch :update_all, :object_type => 'issues', :object_id => '2', :attachments => { '1' => {:filename => 'newname.text', :description => ''}, '4' => {:filename => 'newname.rb', :description => 'Renamed'}, } @@ -399,9 +399,9 @@ class AttachmentsControllerTest < Redmine::ControllerTest assert_equal 'Renamed', attachment.description end - def test_update_with_failure + def test_update_all_with_failure @request.session[:user_id] = 2 - patch :update, :object_type => 'issues', :object_id => '3', :attachments => { + patch :update_all, :object_type => 'issues', :object_id => '3', :attachments => { '1' => {:filename => '', :description => ''}, '4' => {:filename => 'newname.rb', :description => 'Renamed'}, } |