diff options
author | Tünde Tóth <toth.tunde@nisz.hu> | 2023-01-24 15:02:09 +0100 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2023-01-30 11:25:32 +0000 |
commit | f589d7e769bee4b82826a944fed3cf2382d84fb2 (patch) | |
tree | 6ca4ac02b86fa43e7f258158082ba0f03d5b306c /sd | |
parent | 9c9a711ac5d8f32ac318d0e4ecab7b3a26bc2150 (diff) |
tdf#153185 PPTX: fix export of linked OLE objects
Linked OLE objects were not exported.
Change-Id: If6e8c6e0d0c9917e8ec476ad14dcaa1602c74b29
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146073
Tested-by: Jenkins
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/qa/unit/data/odp/linked_ole.odp | bin | 0 -> 15351 bytes | |||
-rw-r--r-- | sd/qa/unit/export-tests-ooxml3.cxx | 18 |
2 files changed, 18 insertions, 0 deletions
diff --git a/sd/qa/unit/data/odp/linked_ole.odp b/sd/qa/unit/data/odp/linked_ole.odp Binary files differnew file mode 100644 index 000000000000..13fb0a845a13 --- /dev/null +++ b/sd/qa/unit/data/odp/linked_ole.odp diff --git a/sd/qa/unit/export-tests-ooxml3.cxx b/sd/qa/unit/export-tests-ooxml3.cxx index 7753abe651ee..2bbb68875760 100644 --- a/sd/qa/unit/export-tests-ooxml3.cxx +++ b/sd/qa/unit/export-tests-ooxml3.cxx @@ -131,6 +131,7 @@ public: void testAutofittedTextboxIndent(); void testTdf151622_oleIcon(); void testTdf152436(); + void testLinkedOLE(); CPPUNIT_TEST_SUITE(SdOOXMLExportTest3); @@ -223,6 +224,7 @@ public: CPPUNIT_TEST(testAutofittedTextboxIndent); CPPUNIT_TEST(testTdf151622_oleIcon); CPPUNIT_TEST(testTdf152436); + CPPUNIT_TEST(testLinkedOLE); CPPUNIT_TEST_SUITE_END(); virtual void registerNamespaces(xmlXPathContextPtr& pXmlXPathCtx) override @@ -2121,6 +2123,22 @@ void SdOOXMLExportTest3::testTdf152436() CPPUNIT_ASSERT_EQUAL(sal_Int32(1), getPage(0)->getCount()); } +void SdOOXMLExportTest3::testLinkedOLE() +{ + createSdImpressDoc("odp/linked_ole.odp"); + + save("Impress Office Open XML"); + + xmlDocUniquePtr pXml = parseExport("ppt/slides/slide1.xml"); + + // Without the accompanying fix in place, this test would have failed with: + // - Expected: 1 + // - Actual : 0 + // - In<>, XPath '//p:oleObj' number of nodes is incorrect + // i.e. the linked ole object wasn't exported. + assertXPath(pXml, "//p:oleObj", 1); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdOOXMLExportTest3); CPPUNIT_PLUGIN_IMPLEMENT(); |