mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-22 11:06:10 +10:00
Improve award emoji test reliability and eliminate sleeps
Closes #14129
This commit is contained in:
@@ -13,7 +13,6 @@ class Spinach::Features::AwardEmoji < Spinach::FeatureSteps
|
||||
thumbsup = page.first('.award-control')
|
||||
thumbsup.click
|
||||
thumbsup.hover
|
||||
sleep 0.3
|
||||
end
|
||||
end
|
||||
|
||||
@@ -46,12 +45,10 @@ class Spinach::Features::AwardEmoji < Spinach::FeatureSteps
|
||||
end
|
||||
|
||||
step 'I have award added' do
|
||||
sleep 0.2
|
||||
|
||||
page.within '.awards' do
|
||||
expect(page).to have_selector '.js-emoji-btn'
|
||||
expect(page.find('.js-emoji-btn.active .js-counter')).to have_content '1'
|
||||
expect(page.find('.js-emoji-btn.active')['data-original-title']).to eq('me')
|
||||
expect(page).to have_css(".js-emoji-btn.active[data-original-title='me']")
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user