HtmlPage page = executePageTest("failCajaTest", null);
NodeList bodyList = page.getElementsByTagName("body");
// Result should contain just one body
assertEquals(1, bodyList.getLength());
DomNode body = (DomNode) bodyList.item(0);
// Failed output contains only an error block plus a onload script block
assertEquals(2, body.getChildNodes().getLength());
assertEquals("ul", body.getFirstChild().getNodeName());
assertEquals("script", body.getLastChild().getNodeName());
}