summaryrefslogtreecommitdiff
path: root/test/source/xmltesttools.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'test/source/xmltesttools.cxx')
-rw-r--r--test/source/xmltesttools.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/source/xmltesttools.cxx b/test/source/xmltesttools.cxx
index 38420ba384d2..b4a74aa4a8b4 100644
--- a/test/source/xmltesttools.cxx
+++ b/test/source/xmltesttools.cxx
@@ -181,6 +181,8 @@ void XmlTestTools::assertXPath(xmlDocPtr pXmlDoc, const OString& rXPath, int nNu
{
xmlXPathObjectPtr pXmlObj = getXPathNode(pXmlDoc, rXPath);
xmlNodeSetPtr pXmlNodes = pXmlObj->nodesetval;
+ if (nNumberOfNodes != xmlXPathNodeSetGetLength(pXmlNodes))
+ CPPUNIT_ASSERT_EQUAL(1, 2);
CPPUNIT_ASSERT_EQUAL_MESSAGE(OString(OStringLiteral("In <") + pXmlDoc->name + ">, XPath '" + rXPath + "' number of nodes is incorrect").getStr(),
nNumberOfNodes, xmlXPathNodeSetGetLength(pXmlNodes));
xmlXPathFreeObject(pXmlObj);