blob: 40540b4b87ca9329bd1f3c33e4e3f7da54cf5c83 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
When (/^I hover over the add new button$/) do
# FIXME: get this working with hover action
page.execute_script("$('.list-title span').show()")
end
When (/^I hover out of the add new button$/) do
# FIXME: get this working with hover action
page.execute_script("$('.list-title span').hide()")
end
Then (/^I should see an "([^"]+)" caption on the add new button$/) do |caption|
button = page.find(:xpath, "//li[contains(@class,\"add-new\")]/a/span[1]")
button.should have_content(caption)
end
Then (/^I should not see an "([^"]+)" caption on the add new button$/) do |caption|
page.should have_no_selector(:xpath, "//li[contains(@class,\"add-new\")]/a/span[1]")
end
|