Hi,
I am using watir+ cucumber. I want to know how to make sure if the multiple 
elements belonging to a same class have been captured and will loop through.
I tried the code:
@browser.links(:class, "more-matches").each do |d|
    d.click
    p d.text
end
Issue faced: the step definition passes without performing any clicks on 
the element belonging to this class because somehow array is empty. Some of 
the results on the page have hidden links belonging to this class and some 
are visible. Can you please tell me how to handle this case.
1. How to wait for all the collection of elements to appear on the page? 
Basically how to add "wait_until_present" for a collection such as divs, 
links, etc.
2. How to identify to click on the visible elements in the loop of 
collection of elements?
3. How to collect the index of a parent element of a particular element in 
a collection?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to