Skip to content

Instantly share code, notes, and snippets.

@levicole
Forked from michaeltwofish/step_definitions.rb
Created March 10, 2011 17:52
Show Gist options
  • Save levicole/864548 to your computer and use it in GitHub Desktop.
Save levicole/864548 to your computer and use it in GitHub Desktop.
Then /^I should see element "([^"]*)" before element "([^"]*)"$/ do |first, second|
xpath = "//*[@id='#{first}']/following-sibling::*[@id='#{second}']"
response_body.should have_xpath(xpath)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment