Hi,
Would it be possible to get a method similar to getSelectOptions()
that returns all of the available values in a Selector?
The reason I'm asking is that I have the following html;
<select name="seat">
<option value="NONE">Choose seat</option>
<option value="CC9">Restaurant</option>
<option value="BC6">Business</option>
<option value="VC4">Voyager</option>
<option value="VCH2">Voyager Wheelchair</option>
<option value="DS7">No Allocated</option>
</select>
Under certain conditions the number at the end of the values changes
(and the application is localised so the text in the label will also
change). One possible solution would be to add attribute partial
matching to selectByValue (similar to that I requested for
selectByLabel in issue #293) then I could do selectByValue("seat",
"^CC") however I have a problem when I get to the VC option as that
would match both VC4 and VCH2. Therefore I would like to be able to
write the following;
def seatType = "VC" // test parameter
getSelectValues("seat").each {value ->
if (value ==~ "${seatType}\\d") {
selectByValue "seat", value
}
}
Does this seem sensible? Are there any other possible workarounds to
select this value (other than running javascript directly)?
Regards,
Jonathan
--
You received this message because you are subscribed to the Google Groups
"tellurium-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/tellurium-users?hl=en.