summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2022-11-02 09:30:30 +0100
committerLászló Németh <nemeth@numbertext.org>2022-11-14 12:19:11 +0100
commit0b224cc5f3c896d8b0064d5cbadc6fce66c8beb9 (patch)
tree185607915706fb01b628ce1b34707c6d5168d5b6 /sd
parent223d0eccaceb1208c5b51d83b4df431a9bed2bbe (diff)
Revert "Revert "tdf#151622 PPTX: fix export of show as icon option""
This reverts commit b652ebda7fa4e6c8db2f934bf4c8d2927f5c2332. Adapt unittest to UnoApiTest Change-Id: I6a1e42d4b445efdb48dab35f0bd5110aa52b0d74 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142156 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sd')
-rw-r--r--sd/qa/unit/data/odp/ole_icon.odpbin0 -> 18926 bytes
-rw-r--r--sd/qa/unit/export-tests-ooxml3.cxx17
2 files changed, 17 insertions, 0 deletions
diff --git a/sd/qa/unit/data/odp/ole_icon.odp b/sd/qa/unit/data/odp/ole_icon.odp
new file mode 100644
index 000000000000..073899c6e564
--- /dev/null
+++ b/sd/qa/unit/data/odp/ole_icon.odp
Binary files differ
diff --git a/sd/qa/unit/export-tests-ooxml3.cxx b/sd/qa/unit/export-tests-ooxml3.cxx
index e5e8cee6c390..c32055df3f42 100644
--- a/sd/qa/unit/export-tests-ooxml3.cxx
+++ b/sd/qa/unit/export-tests-ooxml3.cxx
@@ -129,6 +129,7 @@ public:
void testTdf94122_autoColor();
void testTdf124333();
void testAutofittedTextboxIndent();
+ void testTdf151622_oleIcon();
CPPUNIT_TEST_SUITE(SdOOXMLExportTest3);
@@ -218,6 +219,7 @@ public:
CPPUNIT_TEST(testTdf94122_autoColor);
CPPUNIT_TEST(testTdf124333);
CPPUNIT_TEST(testAutofittedTextboxIndent);
+ CPPUNIT_TEST(testTdf151622_oleIcon);
CPPUNIT_TEST_SUITE_END();
virtual void registerNamespaces(xmlXPathContextPtr& pXmlXPathCtx) override
@@ -2074,6 +2076,21 @@ void SdOOXMLExportTest3::testAutofittedTextboxIndent()
"712800");
}
+void SdOOXMLExportTest3::testTdf151622_oleIcon()
+{
+ loadFromURL(u"odp/ole_icon.odp");
+
+ utl::TempFileNamed tmpfile = save("Impress Office Open XML");
+
+ xmlDocUniquePtr pXml = parseExport(tmpfile, "ppt/slides/slide1.xml");
+
+ // Without the accompanying fix in place, this test would have failed with:
+ // - Expression: prop
+ // - In ..., XPath '//p:oleObj' no attribute 'showAsIcon' exist
+ // i.e. show as icon option wasn't exported.
+ assertXPath(pXml, "//p:oleObj", "showAsIcon", "1");
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(SdOOXMLExportTest3);
CPPUNIT_PLUGIN_IMPLEMENT();