Option for long text custom fields to be displayed under the description field (#21705).

Based on patch by Marius BALTEANU.

git-svn-id: http://svn.redmine.org/redmine/trunk@16251 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2017-01-25 14:55:36 +00:00
parent 8d713ae6ca
commit b40d66f39f
11 changed files with 116 additions and 44 deletions

View File

@@ -126,6 +126,20 @@ class CustomFieldsControllerTest < Redmine::ControllerTest
assert_select '[name=?]', 'custom_field[default_value]', 0
end
def test_setting_full_width_layout_shoul_be_present_only_for_long_text_issue_custom_field
get :new, :type => 'IssueCustomField', :custom_field => {:field_format => 'text'}
assert_response :success
assert_select '[name=?]', 'custom_field[full_width_layout]'
get :new, :type => 'IssueCustomField', :custom_field => {:field_format => 'list'}
assert_response :success
assert_select '[name=?]', 'custom_field[full_width_layout]', 0
get :new, :type => 'TimeEntryCustomField', :custom_field => {:field_format => 'text'}
assert_response :success
assert_select '[name=?]', 'custom_field[full_width_layout]', 0
end
def test_new_js
xhr :get, :new, :type => 'IssueCustomField', :custom_field => {:field_format => 'list'}, :format => 'js'
assert_response :success