In short i have a custom step definition to scroll down a page of search results until a text string is found.
It's scrolling down and finding the text string
But the while loop is not ending, despite it correctly scrolling down and stopping when the text string is found.
This is obviously causing me no end of but hurt.
Then /^I scroll until I see the "This is a test" text$/ do
q = query("android.widget.TextView text:'This is a test'")
while q.empty?
scroll("android.view.View id:'search_listView'", :down)
q = query("android.widget.TextView text:'This is a test'")
end
end
is the ruby that I've been using.