in my gherkin feature I would like to find a certain element that satisfies a logical and. for instance... Then I touch elementWithAnother .
My step def would look for an element that matches two criteria, in this instance it would be the text value and the contentDesciption.
so something like:
Then /^I touch elementWithAnother "([^\"]*)" $/ do |text|text| tap_when_element_exists("RadioButton contentDescription:'#{text}'" && "android.widget.Button {text CONTAINS[c] '#{text}'}"
the logic of this is to touch a radiobutton that matches both conditions (not OR).
Any ideas?
Is it an option just to wrap it in an if sentence?