diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2016-09-03 07:55:57 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2016-09-03 07:55:57 +0000 |
commit | dcf2e15b0617e4e0aa2cc4b7dde2c59b688c535a (patch) | |
tree | f7e9853abca29498ae65e2d46a4ce747eab07ec8 /test/functional | |
parent | fa3a167cdf16eb4952fefc66850a01ccc0a06e7c (diff) | |
download | redmine-dcf2e15b0617e4e0aa2cc4b7dde2c59b688c535a.tar.gz redmine-dcf2e15b0617e4e0aa2cc4b7dde2c59b688c535a.zip |
Bulk edit form not show fields based on target tracker and status (#23755).
git-svn-id: http://svn.redmine.org/redmine/trunk@15815 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional')
-rw-r--r-- | test/functional/issues_controller_test.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/functional/issues_controller_test.rb b/test/functional/issues_controller_test.rb index d4c693a5a..ff37229e2 100644 --- a/test/functional/issues_controller_test.rb +++ b/test/functional/issues_controller_test.rb @@ -3996,6 +3996,20 @@ class IssuesControllerTest < Redmine::ControllerTest assert_select 'input[name=?]', "issue[custom_field_values][#{field2.id}]", 0 end + def test_bulk_edit_should_propose_target_tracker_custom_fields + IssueCustomField.delete_all + field1 = IssueCustomField.generate!(:tracker_ids => [1], :is_for_all => true) + field2 = IssueCustomField.generate!(:tracker_ids => [2], :is_for_all => true) + @request.session[:user_id] = 2 + + issue_ids = Issue.where(:project_id => 1, :tracker_id => 1).limit(2).ids + get :bulk_edit, :ids => issue_ids, :issue => {:tracker_id => 2} + assert_response :success + + assert_select 'input[name=?]', "issue[custom_field_values][#{field1.id}]", 0 + assert_select 'input[name=?]', "issue[custom_field_values][#{field2.id}]" + end + def test_bulk_update @request.session[:user_id] = 2 # update issues priority |