summaryrefslogtreecommitdiff
path: root/sd/qa/unit
diff options
context:
space:
mode:
authorMatus Uzak <matus.uzak@gmail.com>2016-03-08 21:44:21 +0100
committerAndras Timar <andras.timar@collabora.com>2016-06-12 23:30:27 +0200
commit6b7bbca3415b5020e8964c41675633f599a339a8 (patch)
tree7ccbe7e1e19dc221c367ecbf3e8205c3a5f8df42 /sd/qa/unit
parente529dd401d435a62b4a340161d61ae2e771d14d4 (diff)
tdf#93868: PPTX import: Incorrect inheritance of shape fill properties
DrawingML: The useBgFill attribute specifies that the shape fill should be set to that of the slide background. Reviewed-on: https://gerrit.libreoffice.org/23039 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de> (cherry picked from commit f3d1ac75c4b7fa63022e54a9cbff46ba99535076) Change-Id: I8b568e730f00326d51e7b604579f4ff990b26f8a
Diffstat (limited to 'sd/qa/unit')
-rw-r--r--sd/qa/unit/data/pptx/tdf93868.pptxbin0 -> 69213 bytes
-rw-r--r--sd/qa/unit/import-tests.cxx14
2 files changed, 14 insertions, 0 deletions
diff --git a/sd/qa/unit/data/pptx/tdf93868.pptx b/sd/qa/unit/data/pptx/tdf93868.pptx
new file mode 100644
index 000000000000..f54fb0496e11
--- /dev/null
+++ b/sd/qa/unit/data/pptx/tdf93868.pptx
Binary files differ
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index fca3a8a5f047..eb039b281a06 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -112,6 +112,7 @@ public:
void testTdf93830();
void testTdf93097();
void testTdf93124();
+ void testTdf93868();
CPPUNIT_TEST_SUITE(SdImportTest);
@@ -155,6 +156,7 @@ public:
CPPUNIT_TEST(testTdf93830);
CPPUNIT_TEST(testTdf93097);
CPPUNIT_TEST(testTdf93124);
+ CPPUNIT_TEST(testTdf93868);
CPPUNIT_TEST_SUITE_END();
};
@@ -1218,6 +1220,18 @@ void SdImportTest::testTdf93124()
#endif
}
+void SdImportTest::testTdf93868()
+{
+ sd::DrawDocShellRef xDocShRef = loadURL(getURLFromSrc("/sd/qa/unit/data/pptx/tdf93868.pptx"), PPTX);
+
+ const SdrPage *pPage = &(GetPage( 1, xDocShRef )->TRG_GetMasterPage());
+ CPPUNIT_ASSERT_EQUAL(size_t(5), pPage->GetObjCount());
+ CPPUNIT_ASSERT_EQUAL(drawing::FillStyle_SOLID, dynamic_cast<const XFillStyleItem&>(pPage->GetObj(0)->GetMergedItem(XATTR_FILLSTYLE)).GetValue());
+ CPPUNIT_ASSERT_EQUAL(drawing::FillStyle_GRADIENT, dynamic_cast<const XFillStyleItem&>(pPage->GetObj(1)->GetMergedItem(XATTR_FILLSTYLE)).GetValue());
+
+ xDocShRef->DoClose();
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(SdImportTest);
CPPUNIT_PLUGIN_IMPLEMENT();