diff options
Diffstat (limited to 'sc/qa/unit')
-rw-r--r-- | sc/qa/unit/data/xlsx/tdf139167.xlsx | bin | 0 -> 10743 bytes | |||
-rw-r--r-- | sc/qa/unit/subsequent_export-test.cxx | 21 |
2 files changed, 21 insertions, 0 deletions
diff --git a/sc/qa/unit/data/xlsx/tdf139167.xlsx b/sc/qa/unit/data/xlsx/tdf139167.xlsx Binary files differnew file mode 100644 index 000000000000..b1c7aa201713 --- /dev/null +++ b/sc/qa/unit/data/xlsx/tdf139167.xlsx diff --git a/sc/qa/unit/subsequent_export-test.cxx b/sc/qa/unit/subsequent_export-test.cxx index 6c68d2b02183..972004c28431 100644 --- a/sc/qa/unit/subsequent_export-test.cxx +++ b/sc/qa/unit/subsequent_export-test.cxx @@ -89,6 +89,7 @@ public: virtual void tearDown() override; void test(); + void testTdf139167(); void testTdf139394(); void testExtCondFormatXLSX(); void testTdf90104(); @@ -283,6 +284,7 @@ public: CPPUNIT_TEST_SUITE(ScExportTest); CPPUNIT_TEST(test); + CPPUNIT_TEST(testTdf139167); CPPUNIT_TEST(testTdf139394); CPPUNIT_TEST(testExtCondFormatXLSX); CPPUNIT_TEST(testTdf90104); @@ -525,6 +527,25 @@ void ScExportTest::test() xDocSh->DoClose(); } +void ScExportTest::testTdf139167() +{ + ScDocShellRef xShell = loadDoc(u"tdf139167.", FORMAT_XLSX); + CPPUNIT_ASSERT(xShell.is()); + + ScDocShellRef xDocSh = saveAndReload(&(*xShell), FORMAT_XLSX); + CPPUNIT_ASSERT(xDocSh.is()); + + std::shared_ptr<utl::TempFile> pXPathFile = ScBootstrapFixture::exportTo(&(*xDocSh), FORMAT_XLSX); + xmlDocUniquePtr pDoc = XPathHelper::parseExport(pXPathFile, m_xSFactory, "xl/styles.xml"); + CPPUNIT_ASSERT(pDoc); + + assertXPath(pDoc, "/x:styleSheet/x:cellStyles", "count", "6"); + assertXPath(pDoc, "/x:styleSheet/x:dxfs/x:dxf/x:fill/x:patternFill/x:bgColor", "rgb", + "FFFFFF00"); + + xDocSh->DoClose(); +} + void ScExportTest::testTdf139394() { ScDocShellRef xShell = loadDoc(u"tdf139394.", FORMAT_XLSX); |