Skip to content

Instantly share code, notes, and snippets.

@ssaadh
Created January 31, 2014 23:06
Show Gist options
  • Save ssaadh/8745139 to your computer and use it in GitHub Desktop.
Save ssaadh/8745139 to your computer and use it in GitHub Desktop.
## Examples ##
def target_parent
target_parent = browser.divs( class: 'card' ).find { |div| div.div( class: 'title', text: 'AAAA' ).exists? }
end
def target_element
target_parent = browser.divs( class: 'card' ).find { |div| div.div( class: 'title', text: 'AAAA' ).exists? }
target_element = target_parent.div( class: 'title', text: 'AAAA' )
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment