assertNotNull(secondElement);
assertEquals(secondElement.getText(), text);
}
public void testAddLLOMTextChildToDOOM() throws XMLStreamException {
OMFactory doomFactory = OMAbstractFactory.getMetaFactory(OMAbstractFactory.FEATURE_DOM).getOMFactory();
OMFactory llomFactory = OMAbstractFactory.getOMFactory();
String text = "This was a DOOM Text";
OMElement doomRoot = doomFactory.createOMElement("root", null);
OMText llomText = llomFactory.createOMText(text);
OMComment comment = llomFactory.createOMComment(null, "comment");
doomRoot.addChild(llomText);
doomRoot.addChild(comment);
OMElement newElement = (OMXMLBuilderFactory.createStAXOMBuilder(this.factory, doomRoot
.getXMLStreamReader())).getDocumentElement();