Simplify.

Change-Id: If20ed2636c9b3cfbfcfe058fe027bd0cc9f8f277
This commit is contained in:
Jan Holesovsky
2014-03-24 09:43:39 +01:00
parent 4365d3c120
commit ece15872c8

View File

@@ -615,15 +615,7 @@ protected:
*/
void assertXPathContent(xmlDocPtr pXmlDoc, const OString& rXPath, const OUString& rContent)
{
xmlNodeSetPtr pXmlNodes = getXPathNode(pXmlDoc, rXPath);
CPPUNIT_ASSERT_MESSAGE(OString("XPath '" + rXPath + "' not found").getStr(),
xmlXPathNodeSetGetLength(pXmlNodes) > 0);
xmlNodePtr pXmlNode = pXmlNodes->nodeTab[0];
CPPUNIT_ASSERT_EQUAL_MESSAGE("XPath contents of child does not match", rContent,
OUString::createFromAscii((const char*)((pXmlNode->children[0]).content)));
CPPUNIT_ASSERT_EQUAL_MESSAGE("XPath contents of child does not match", rContent, getXPathContent(pXmlDoc, rXPath));
}
/**