Defect #5593 » tests_for_5593.patch
test/functional/workflows_controller_test.rb | ||
---|---|---|
110 | 110 |
assert_equal ["New issue"] + statuses, |
111 | 111 |
css_select('table.workflows.transitions-always tbody tr td:first').map(&:text).map(&:strip) |
112 | 112 | |
113 |
assert_select 'input[type=checkbox][name=?]', 'transitions[1][1][always]' |
|
113 |
assert_select 'input[type=checkbox][name=?]', 'transitions[0][1][always]' |
|
114 |
end |
|
115 | ||
116 |
def test_get_edit_should_not_show_checkboxes_for_transitions_between_the_same_statuses |
|
117 |
get :edit, :params => {:role_id => 2, :tracker_id => 1} |
|
118 |
assert_response :success |
|
119 | ||
120 |
assert_select 'table.workflows.transitions-always tbody tr:nth-child(2)' do |
|
121 |
assert_select 'td.name', :text => 'New' |
|
122 |
# assert that "-" is shown instead of a checkbox |
|
123 |
assert_select 'td[title=?]', 'New » New', :text => '-' |
|
124 |
assert_select 'input[name=?]', 'transitions[1][1][always]', 0 |
|
125 |
assert_select 'input[name=?]', 'transitions[2][2][always]', 0 |
|
126 |
end |
|
114 | 127 |
end |
115 | 128 | |
116 | 129 |
def test_post_edit |