diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-21 02:50:22 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-21 02:50:22 +0300 |
commit | 9dc93a4519d9d5d7be48ff274127136236a3adb3 (patch) | |
tree | 70467ae3692a0e35e5ea56bcb803eb512a10bedb /spec/features/merge_request/user_awards_emoji_spec.rb | |
parent | 4b0f34b6d759d6299322b3a54453e930c6121ff0 (diff) |
Add latest changes from gitlab-org/gitlab@13-11-stable-eev13.11.0-rc43
Diffstat (limited to 'spec/features/merge_request/user_awards_emoji_spec.rb')
-rw-r--r-- | spec/features/merge_request/user_awards_emoji_spec.rb | 29 |
1 files changed, 12 insertions, 17 deletions
diff --git a/spec/features/merge_request/user_awards_emoji_spec.rb b/spec/features/merge_request/user_awards_emoji_spec.rb index 62e4209f386..6f46cc20cba 100644 --- a/spec/features/merge_request/user_awards_emoji_spec.rb +++ b/spec/features/merge_request/user_awards_emoji_spec.rb @@ -17,33 +17,28 @@ RSpec.describe 'Merge request > User awards emoji', :js do end it 'adds award to merge request' do - first('.js-emoji-btn').click - expect(page).to have_selector('.js-emoji-btn.active') - expect(first('.js-emoji-btn')).to have_content '1' + first('[data-testid="award-button"]').click + expect(page).to have_selector('[data-testid="award-button"].is-active') + expect(first('[data-testid="award-button"]')).to have_content '1' visit project_merge_request_path(project, merge_request) - expect(first('.js-emoji-btn')).to have_content '1' + expect(first('[data-testid="award-button"]')).to have_content '1' end it 'removes award from merge request' do - first('.js-emoji-btn').click - find('.js-emoji-btn.active').click - expect(first('.js-emoji-btn')).to have_content '0' + first('[data-testid="award-button"]').click + find('[data-testid="award-button"].is-active').click + expect(first('[data-testid="award-button"]')).to have_content '0' visit project_merge_request_path(project, merge_request) - expect(first('.js-emoji-btn')).to have_content '0' - end - - it 'has only one menu on the page' do - first('.js-add-award').click - expect(page).to have_selector('.emoji-menu') - - expect(page).to have_selector('.emoji-menu', count: 1) + expect(first('[data-testid="award-button"]')).to have_content '0' end it 'adds awards to note' do - first('.js-note-emoji').click - first('.emoji-menu .js-emoji-btn').click + page.within('.note-actions') do + first('.note-emoji-button').click + find('gl-emoji[data-name="8ball"]').click + end wait_for_requests |