如何在jsf单元中显示rich:modalPanel?
我正在运行一个如何在jsf单元中显示rich:modalPanel?,jsf,richfaces,jsfunit,Jsf,Richfaces,Jsfunit,我正在运行一个jsf单元测试,它包括测试是否显示一个模式,我想测试模式内部的一些操作,但是isDisplayed总是false 这里有什么我遗漏的吗 下面是我的一段代码: HtmlSelect mSelection = (HtmlSelect) client.getElement("selecID"); assertTrue( mSelection.isDisplayed() ); assertFalse( mSelection.isDisabled() );
jsf
单元测试,它包括测试是否显示一个模式,我想测试模式内部的一些操作,但是isDisplayed
总是false
这里有什么我遗漏的吗
下面是我的一段代码:
HtmlSelect mSelection = (HtmlSelect) client.getElement("selecID");
assertTrue( mSelection.isDisplayed() );
assertFalse( mSelection.isDisabled() );
HtmlOption mOption = mOption .getOptionByValue("18");
mOption .setSelected(true);
try {
mOption .click();
} catch (IOException e2) {
e2.printStackTrace();
}
System.out.println(" SELECTED = " + mOption .getText());
HtmlButtonInput goButton = (HtmlButtonInput) client.getElement("goButton");
assertTrue( goButton.isDisplayed() );
assertFalse( goButton.isDisabled() );
try {
goButton.click();
} catch (IOException e) {
}
try {
Thread.sleep(10000);
} catch (InterruptedException e1) {
e1.printStackTrace();
}
//This part is inside the modal
HtmlSelect mmSetSelection = (HtmlSelect) client.getElement("mmSelection");
assertTrue( mmSetSelection!= null );
System.out.println(" IS DIAPLED? = " + mmSetSelection.isDisplayed() );