Defect #35192 » 0002-fix-test-failures-watchers-dialog-pagination.patch
| app/controllers/watchers_controller.rb | ||
|---|---|---|
| 201 | 201 |
if @watchables.blank? || @watchables.all? {|w| w.valid_watcher?(user)}
|
| 202 | 202 |
valid_users << user |
| 203 | 203 |
if valid_users.size == limit |
| 204 |
has_more = has_more || (idx + 1 < batch.size)
|
|
| 204 |
has_more ||= (idx + 1 < batch.size)
|
|
| 205 | 205 |
current_offset += (idx + 1) |
| 206 | 206 |
break |
| 207 | 207 |
end |
| test/functional/watchers_controller_test.rb | ||
|---|---|---|
| 210 | 210 |
assert_response :success |
| 211 | 211 | |
| 212 | 212 |
assert_match( |
| 213 |
%r{/watchers/autocomplete_for_user\?object_id%5B%5D=7&object_id%5B%5D=9&object_type=issue},
|
|
| 213 |
%r{/watchers/autocomplete_for_user\?object_id%5B%5D=7&object_id%5B%5D=9&object_type=issue},
|
|
| 214 | 214 |
response.body |
| 215 | 215 |
) |
| 216 | 216 |
end |
| test/system/watchers_test.rb | ||
|---|---|---|
| 94 | 94 |
click_on 'Add' |
| 95 | 95 |
end |
| 96 | 96 | |
| 97 |
user1 = user2 = nil |
|
| 98 | ||
| 97 | 99 |
within '#ajax-modal' do |
| 98 | 100 |
assert page.has_css?('p.watcher-more-users a', text: 'Show more')
|
| 99 | 101 | |
- « Previous
- 1
- …
- 5
- 6
- 7
- Next »