diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2015-04-30 05:24:55 +0200 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2015-04-30 08:13:19 +0200 |
commit | d38b6043040f778ab36522dd8697dce388c437d9 (patch) | |
tree | c4aaccae84a625a50fd920c04f805b8d40663ad3 | |
parent | 1e033254927750affcd1dcc0e10c48f076ebec13 (diff) |
add test for plotVisOnly default value
Change-Id: I0b0a5df307bc5478283fbbe48a0016256b9cf7cd
-rw-r--r-- | chart2/qa/extras/chart2import.cxx | 15 | ||||
-rw-r--r-- | chart2/qa/extras/data/xlsx/plotVisOnly.xlsx | bin | 0 -> 11206 bytes |
2 files changed, 15 insertions, 0 deletions
diff --git a/chart2/qa/extras/chart2import.cxx b/chart2/qa/extras/chart2import.cxx index 9150b305c1b3..c559ddad94f5 100644 --- a/chart2/qa/extras/chart2import.cxx +++ b/chart2/qa/extras/chart2import.cxx @@ -78,6 +78,7 @@ public: void testTrendlineDefaultValue2013XLSX(); void testVaryColorDefaultValues2007XLSX(); void testVaryColorDefaultValues2013XLSX(); + void testPlotVisOnlyDefaultValue2013XLSX(); CPPUNIT_TEST_SUITE(Chart2ImportTest); CPPUNIT_TEST(Fdo60083); @@ -119,6 +120,7 @@ public: CPPUNIT_TEST(testTrendlineDefaultValue2013XLSX); CPPUNIT_TEST(testVaryColorDefaultValues2007XLSX); CPPUNIT_TEST(testVaryColorDefaultValues2013XLSX); + CPPUNIT_TEST(testPlotVisOnlyDefaultValue2013XLSX); CPPUNIT_TEST_SUITE_END(); private: @@ -944,6 +946,19 @@ void Chart2ImportTest::testVaryColorDefaultValues2013XLSX() CPPUNIT_ASSERT(bVaryColor); } +void Chart2ImportTest::testPlotVisOnlyDefaultValue2013XLSX() +{ + load("/chart2/qa/extras/data/xlsx/", "plotVisOnly.xlsx"); + uno::Reference< chart::XChartDocument > xChart1Doc ( getChartCompFromSheet( 0, mxComponent ), UNO_QUERY_THROW); + CPPUNIT_ASSERT_MESSAGE("failed to load chart", xChart1Doc.is()); + Reference<beans::XPropertySet> xPropSet(xChart1Doc->getDiagram(), uno::UNO_QUERY_THROW); + uno::Any aAny = xPropSet->getPropertyValue("IncludeHiddenCells"); + CPPUNIT_ASSERT(aAny.hasValue()); + bool bShowHiddenValues = true; + CPPUNIT_ASSERT(aAny >>= bShowHiddenValues); + CPPUNIT_ASSERT(!bShowHiddenValues); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ImportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/chart2/qa/extras/data/xlsx/plotVisOnly.xlsx b/chart2/qa/extras/data/xlsx/plotVisOnly.xlsx Binary files differnew file mode 100644 index 000000000000..8e4fcbd5ea68 --- /dev/null +++ b/chart2/qa/extras/data/xlsx/plotVisOnly.xlsx |