sw/qa/extras/ooxmlexport/data/tdf104418.odt |binary
 sw/qa/extras/ooxmlexport/ooxmlexport10.cxx  |   14 ++++++++++++++
 2 files changed, 14 insertions(+)

New commits:
commit 6e0a512da826e2856e7d36200a878b64907816c8
Author:     Xisco Fauli <xiscofa...@libreoffice.org>
AuthorDate: Wed Nov 24 15:51:06 2021 +0100
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Wed Nov 24 23:07:11 2021 +0100

    tdf#104418: sw_ooxmlexport10: Add unittest
    
    Change-Id: I3e7b1913edbdcb14da4ceb962879b67f69fb2345
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125777
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/sw/qa/extras/ooxmlexport/data/tdf104418.odt 
b/sw/qa/extras/ooxmlexport/data/tdf104418.odt
new file mode 100644
index 000000000000..12627ea2863e
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf104418.odt differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
index 35f2ccaba137..985b378912f0 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport10.cxx
@@ -778,6 +778,20 @@ DECLARE_OOXMLEXPORT_TEST(testFdo80555, "fdo80555.docx")
     CPPUNIT_ASSERT_EQUAL(sal_Int32(247), xShape->getPosition().Y);
 }
 
+DECLARE_OOXMLEXPORT_TEST(testTdf104418, "tdf104418.odt")
+{
+    // Problem was that <w:hideMark> cell property was ignored.
+    uno::Reference<text::XTextTablesSupplier> xTablesSupplier(mxComponent, 
uno::UNO_QUERY);
+    uno::Reference<container::XIndexAccess> 
xTables(xTablesSupplier->getTextTables( ), uno::UNO_QUERY);
+    uno::Reference<text::XTextTable> xTextTable(xTables->getByIndex(0), 
uno::UNO_QUERY);
+    uno::Reference<table::XTableRows> xTableRows = xTextTable->getRows();
+
+    // Without the fix in place, this test would have failed with
+    // - Expected: 750
+    // - Actual  : 1499
+    CPPUNIT_ASSERT_EQUAL(sal_Int64(750) , 
getProperty<sal_Int64>(xTableRows->getByIndex(0), "Height"));
+}
+
 DECLARE_OOXMLEXPORT_TEST(testHidemark, "hidemark.docx")
 {
     // Problem was that <w:hideMark> cell property was ignored.

Reply via email to