tdf#72520: fix test

This test should fail if oox/source/export/chartexport.cxx:970
is commented out
The reason is that the assert should have been
CPPUNIT_ASSERT(xmlXPathNodeSetGetLength(pXmlNodes));
instead.
Anyway, simplify it and just use assertXPath

Change-Id: Ie7ec10a70f7b447f92735d5c5b28d1074a9e4f98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148118
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx
index 00c5d3a..a5ccc4b 100644
--- a/chart2/qa/extras/chart2export.cxx
+++ b/chart2/qa/extras/chart2export.cxx
@@ -442,9 +442,7 @@ CPPUNIT_TEST_FIXTURE(Chart2ExportTest, testChartExternalData)

    xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text");
    CPPUNIT_ASSERT(pXmlDoc);
    xmlXPathObjectPtr pXmlPathObj = getXPathNode(pXmlDoc, "/c:chartSpace/c:externalData");
    xmlNodeSetPtr pXmlNodes = pXmlPathObj->nodesetval;
    CPPUNIT_ASSERT(pXmlNodes);
    assertXPath(pXmlDoc, "/c:chartSpace/c:externalData");
}

CPPUNIT_TEST_FIXTURE(Chart2ExportTest, testEmbeddingsGrabBag)