/** * Runs the test case. * @throws Throwable Any uncaught exception causes test to fail */ public void runTest() throws Throwable { Document doc; Element docElem; Element elem; Comment comment; Comment clonedComment; String namespaceURI; Node appendedChild; doc = (Document) load("hc_staff", true); docElem = doc.getDocumentElement(); elem = doc.createElementNS("http://www.w3.org/1999/xhtml", "dom3:p"); comment = doc.createComment("Text"); clonedComment = (Comment) comment.cloneNode(true); appendedChild = elem.appendChild(clonedComment); appendedChild = docElem.appendChild(elem); namespaceURI = clonedComment.lookupNamespaceURI("dom3"); assertEquals("nodelookupnamespaceuri15", "http://www.w3.org/1999/xhtml", namespaceURI); } /**
/** * Runs the test case. * @throws Throwable Any uncaught exception causes test to fail */ public void runTest() throws Throwable { Document doc; Element bodyElem; Element elem; Comment comment; Comment clonedComment; String prefix; Node appendedChild; NodeList bodyList; doc = (Document) load("hc_staff", true); bodyList = doc.getElementsByTagName("body"); bodyElem = (Element) bodyList.item(0); elem = doc.createElementNS("http://www.w3.org/1999/xhtml", "dom3:p"); comment = doc.createComment("Text"); clonedComment = (Comment) comment.cloneNode(true); appendedChild = elem.appendChild(clonedComment); appendedChild = bodyElem.appendChild(elem); prefix = clonedComment.lookupPrefix("http://www.w3.org/1999/xhtml"); assertEquals("nodelookupprefix15", "dom3", prefix); } /**
/** * Runs the test case. * @throws Throwable Any uncaught exception causes test to fail */ public void runTest() throws Throwable { Document doc; Element bodyElem; Element elem; Comment comment; Comment clonedComment; boolean isDefault; Node appendedChild; NodeList bodyList; doc = (Document) load("hc_staff", true); bodyList = doc.getElementsByTagName("body"); bodyElem = (Element) bodyList.item(0); elem = doc.createElementNS("http://www.w3.org/1999/xhtml", "p"); comment = doc.createComment("Text"); clonedComment = (Comment) comment.cloneNode(true); appendedChild = elem.appendChild(clonedComment); appendedChild = bodyElem.appendChild(elem); isDefault = clonedComment.isDefaultNamespace("http://www.w3.org/1999/xhtml"); assertTrue("nodeisdefaultnamespace15", isDefault); } /**