I am using the WATIR-Ruby for my Web Application. I am currently facing an issue clicking on a text element that is populated dynamically when a search bar is partially/completely filled with text. The code is unable to identify the element I am trying to click.
http://i.stack.imgur.com/q5Hmv.png
I am unable to click on any of the results obtained from the search.
Here is the HTML source :
<div class="results" style="display: block;">
<ul>
<li nodeid="111">Profile_Child</li>
<li nodeid="222">Profile_Grandchild</li>
<li nodeid="333">Rest_Child2</li>
<li nodeid="444">rest_grandchild2</li>
</ul>
</div>
How would I code for clicking these elements in Ruby/Watir?