@@ -543,11 +543,13 class IssueTest < ActiveSupport::TestCase | |||||
543 | end |
|
543 | end | |
544 |
|
544 | |||
545 | def test_editable_custom_field_values_should_return_non_readonly_custom_values |
|
545 | def test_editable_custom_field_values_should_return_non_readonly_custom_values | |
546 |
cf1 = IssueCustomField.create!(:name => 'Writable field', :field_format => 'string', |
|
546 | cf1 = IssueCustomField.create!(:name => 'Writable field', :field_format => 'string', | |
547 | cf2 = IssueCustomField.create!(:name => 'Readonly field', :field_format => 'string', :is_for_all => true, :tracker_ids => [1, 2]) |
|
547 | :is_for_all => true, :tracker_ids => [1, 2]) | |
548 |
|
548 | cf2 = IssueCustomField.create!(:name => 'Readonly field', :field_format => 'string', | ||
|
549 | :is_for_all => true, :tracker_ids => [1, 2]) | |||
549 | WorkflowPermission.delete_all |
|
550 | WorkflowPermission.delete_all | |
550 |
WorkflowPermission.create!(:old_status_id => 1, :tracker_id => 1, :role_id => 1, |
|
551 | WorkflowPermission.create!(:old_status_id => 1, :tracker_id => 1, :role_id => 1, | |
|
552 | :field_name => cf2.id.to_s, :rule => 'readonly') | |||
551 | user = User.find(2) |
|
553 | user = User.find(2) | |
552 |
|
554 | |||
553 | issue = Issue.new(:project_id => 1, :tracker_id => 1) |
|
555 | issue = Issue.new(:project_id => 1, :tracker_id => 1) |
General Comments 0
You need to be logged in to leave comments.
Login now