BigW Consortium Gitlab

Commit fc75de7d by Robert Speicher

Merge branch 'improve-award-emoji-spinach-tests' into 'master'

Improve award emoji test reliability by checking that the emoji is displayed before the search field is focused See merge request !3288
parents 4c517ce6 0901d517
......@@ -18,21 +18,24 @@ Feature: Award Emoji
@javascript
Scenario: I add and remove custom award in the issue
Given I click to emoji-picker
Then The search field is focused
And I click to emoji in the picker
Then The emoji menu is visible
And The search field is focused
Then I click to emoji in the picker
Then I have award added
And I can remove it by clicking to icon
@javascript
Scenario: I can see the list of emoji categories
Given I click to emoji-picker
Then The search field is focused
Then The emoji menu is visible
And The search field is focused
Then I can see the activity and food categories
@javascript
Scenario: I can search emoji
Given I click to emoji-picker
Then The search field is focused
Then The emoji menu is visible
And The search field is focused
And I search "hand"
Then I see search result for "hand"
......
......@@ -92,6 +92,10 @@ class Spinach::Features::AwardEmoji < Spinach::FeatureSteps
end
end
step 'The emoji menu is visible' do
page.find(".emoji-menu.is-visible")
end
step 'The search field is focused' do
expect(page).to have_selector('#emoji_search')
expect(page.evaluate_script('document.activeElement.id')).to eq('emoji_search')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment