diff options
author | Tünde Tóth <tundeth@gmail.com> | 2020-05-26 13:34:32 +0200 |
---|---|---|
committer | Xisco Fauli <xiscofauli@libreoffice.org> | 2020-06-01 18:25:05 +0200 |
commit | 59a896d80feee9f4c25b931c77aee281da189868 (patch) | |
tree | 3b9982b1994821d4091698db00a1f282e49c0b04 /chart2 | |
parent | 4c75fe312fd15dfe0556c6342586edae4ca5015d (diff) |
tdf#132594 Chart XLSX import: fix legend entries in pie charts
Legend entry text of pie chart wasn't imported correctly
in XLSX documents created with Excel 2007.
Regression from commit: e0b0502516a10181bbd1737b93b38b2bba4c98e8
(tdf#128016 Chart OOXML Import: fix duplicated category labels)
Change-Id: I4567437a41fe66e124dccbd148c0c49196d5c007
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94864
Tested-by: Jenkins
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95294
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/qa/extras/chart2export.cxx | 11 | ||||
-rw-r--r-- | chart2/qa/extras/data/xlsx/chart_pie2007.xlsx | bin | 0 -> 11299 bytes |
2 files changed, 11 insertions, 0 deletions
diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx index 6826c3f53569..cb9e4aa32df3 100644 --- a/chart2/qa/extras/chart2export.cxx +++ b/chart2/qa/extras/chart2export.cxx @@ -152,6 +152,7 @@ public: void testTdf123206_customLabelText(); void testCustomLabelText(); void testTdf131979(); + void testTdf132594(); CPPUNIT_TEST_SUITE(Chart2ExportTest); CPPUNIT_TEST(testErrorBarXLSX); @@ -267,6 +268,7 @@ public: CPPUNIT_TEST(testTdf123206_customLabelText); CPPUNIT_TEST(testCustomLabelText); CPPUNIT_TEST(testTdf131979); + CPPUNIT_TEST(testTdf132594); CPPUNIT_TEST_SUITE_END(); @@ -2467,6 +2469,15 @@ void Chart2ExportTest::testTdf131979() } } +void Chart2ExportTest::testTdf132594() +{ + load("/chart2/qa/extras/data/xlsx/", "chart_pie2007.xlsx"); + xmlDocPtr pXmlDoc = parseExport("xl/charts/chart","Calc Office Open XML"); + CPPUNIT_ASSERT(pXmlDoc); + + assertXPath(pXmlDoc, "/c:chartSpace/c:chart/c:plotArea/c:pieChart/c:ser/c:cat", 1); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ExportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/chart2/qa/extras/data/xlsx/chart_pie2007.xlsx b/chart2/qa/extras/data/xlsx/chart_pie2007.xlsx Binary files differnew file mode 100644 index 000000000000..b122680257c0 --- /dev/null +++ b/chart2/qa/extras/data/xlsx/chart_pie2007.xlsx |