Feature Requests item #5289, was opened at 2006-08-03 12:52
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=490&aid=5289&group_id=104

Category: General
Group: None
Status: Open
Resolution: None
Priority: 3
Submitted By: Ben Mills (benmills)
Assigned to: Nobody (None)
Summary: Asserting that a particular option is selected in a drop down

Initial Comment:
I have a situation where I'm using the querystring of the URL to preselect an 
option in a drop down.  I want to assert the correct option is selected.  It 
seems like the best way for me to get the selected option is:

ie.select_list(:name, "thename").getSelectedItems()[0]

I thought that this would return an object that would allow me to get either 
the text or the value of the option.  However, it seems to just return the text 
as a string.  I really want to be able to get the value of the selected option 
(the text could change and make the text fail, but the value is fixed).

In the API documentation I noticed the Watir::OptionAccess object which allows 
access to both the value and the text, but I can't see any way to get this 
object.

Maybe I'm missing something.

Thanks,
Ben Mills

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=490&aid=5289&group_id=104
_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to