[jboss-user] [JBoss Seam] - Re: Integration testing action events or value change events
tangdazhu
do-not-reply at jboss.com
Wed Jun 13 01:08:43 EDT 2007
i have solved this problem by using NonFacesRequest, i pasted the codes here, hope it will be helpful for someone :
@Test
public void testChangeDataset() throws Exception {
new NonFacesRequest() {
@Override
protected void invokeApplication() {
UserBean userBean = (UserBean) Component
.getInstance(UserBean.class);
userBean.setDatasetId(0);
this.invokeMethod("#{userBean.changeDropdown}");
Dataset set = userBean.getCurrentDataset();
assert set!=null;
}
}.run();
}
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4053797#4053797
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4053797
More information about the jboss-user
mailing list