How can i select a value in dropdown list per JSFUnit?

Posted by easyrider on Stack Overflow See other posts from Stack Overflow or by easyrider
Published on 2010-06-03T17:50:49Z Indexed on 2010/06/03 17:54 UTC
Read the original article Hit count: 227

Filed under:

Hi,

I would like to change a value in dropdown list with id "items".

The following causes error

client.setValue("items", "1");

java.lang.IllegalArgumentException: This method can not be used on components of type com.gargoylesoftware.htmlunit.html.HtmlSelect

I've tried:

client.getElement("items").setAttribute("value","1");

It causes no error and no effect as well.

Is there any possibility to solve it?

Thanx in advance

© Stack Overflow or respective owner

Related posts about jsfunit