use #hover instead of execute_script hacks
This commit is contained in:
parent
d489dfc8e3
commit
cdfdf37a17
3 changed files with 4 additions and 3 deletions
|
|
@ -1,7 +1,7 @@
|
||||||
When /^I click on "([^"]*)" aspect edit icon$/ do |aspect_name|
|
When /^I click on "([^"]*)" aspect edit icon$/ do |aspect_name|
|
||||||
within(".all_aspects") do
|
within(".all_aspects") do
|
||||||
li = find('li', text: aspect_name)
|
li = find('li', text: aspect_name)
|
||||||
page.execute_script("$('#aspects_list li:contains(\\'#{aspect_name}\\') .modify_aspect').css('display', 'block');") # TODO HACK please replace me by li.hover when capybara will be fixed
|
li.hover
|
||||||
li.find('.modify_aspect').click
|
li.find('.modify_aspect').click
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -41,6 +41,7 @@ Then /^I should see "([^"]*)" as part of the participants popover$/ do |name|
|
||||||
end
|
end
|
||||||
|
|
||||||
Then /^I close the participants popover$/ do
|
Then /^I close the participants popover$/ do
|
||||||
find('.popover-title .close', visible: false).click
|
find('.popover').hover
|
||||||
|
find('.popover-title .close').click
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -114,7 +114,7 @@ And /^I want to mention (?:him|her) from the profile$/ do
|
||||||
end
|
end
|
||||||
|
|
||||||
And /^I hover over the "([^"]+)"$/ do |element|
|
And /^I hover over the "([^"]+)"$/ do |element|
|
||||||
page.execute_script("$(\"#{element}\").first().addClass('hover')")
|
find("#{element}", match: :first).hover
|
||||||
end
|
end
|
||||||
|
|
||||||
When /^I prepare the deletion of the first post$/ do
|
When /^I prepare the deletion of the first post$/ do
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue