browser.get(contextPath.toExternalForm() + "index.jsf");
guardAjax(button).click();
}
private static void addIndexPage(RichDeployment deployment) {
FaceletAsset p = new FaceletAsset();
p.body("<h:form id='myForm'>");
p.body("<rich:togglePanel id='fieldsPanel' activeItem='closed'> ");
p.body(" <rich:togglePanelItem name='closed'> ");
p.body(" <h:commandButton value='Show fields' styleClass='submit'> ");
p.body(" <rich:toggleControl targetItem='checkboxes' /> ");
p.body(" </h:commandButton> ");
p.body(" </rich:togglePanelItem> ");
p.body(" <rich:togglePanelItem name='checkboxes'> ");
p.body(" Lorem ipsum dolor sit amet, ... ");
p.body(" </rich:togglePanelItem> ");
p.body("</rich:togglePanel> ");
p.body("</h:form>");
deployment.archive().addAsWebResource(p, "index.xhtml");
}