chart2/qa/extras/chart2export.cxx | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)
New commits: commit ceae73dd294b5ca4073062afc1223efb1c206780 Author: Daniel Arato (NISZ) <[email protected]> AuthorDate: Mon Aug 31 13:10:26 2020 +0200 Commit: Mike Kaganski <[email protected]> CommitDate: Tue Sep 1 09:04:06 2020 +0200 tdf#129423 sw: Make yet more tests export-only This commit continues an earlier, incomplete unit test refactor under the same bug ticket number. Eliminates a few unwanted nullptr tests in chart2/qa/. Change-Id: I6bd5c24ba264793ebe8fff20ba954be0d1e84882 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101540 Tested-by: Mike Kaganski <[email protected]> Reviewed-by: Mike Kaganski <[email protected]> diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx index 7e17c2f1307c..3e1f5d86e897 100644 --- a/chart2/qa/extras/chart2export.cxx +++ b/chart2/qa/extras/chart2export.cxx @@ -655,8 +655,7 @@ void Chart2ExportTest::testStockChart() load("/chart2/qa/extras/data/docx/", "testStockChart.docx"); xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text"); - if (!pXmlDoc) - return; + CPPUNIT_ASSERT(pXmlDoc); assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:stockChart/c:ser[1]/c:idx", "val", "1"); assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:stockChart/c:ser[1]/c:order", "val", "1"); @@ -670,8 +669,7 @@ void Chart2ExportTest::testBarChart() { load("/chart2/qa/extras/data/docx/", "testBarChart.docx"); xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text"); - if (!pXmlDoc) - return; + CPPUNIT_ASSERT(pXmlDoc); assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:barChart/c:barDir", "val", "col"); } @@ -727,8 +725,7 @@ void Chart2ExportTest::testScatterChartTextXValues() // Test the export. xmlDocUniquePtr pXmlDoc = parseExport("word/charts/chart", "Office Open XML Text"); - if (!pXmlDoc) - return; + CPPUNIT_ASSERT(pXmlDoc); assertXPathContent(pXmlDoc, "//c:scatterChart/c:ser[1]/c:xVal[1]/c:numRef[1]/c:numCache[1]/c:pt[1]/c:v[1]", "1"); } _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
