summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf118691.docxbin0 -> 27096 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport11.cxx12
2 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf118691.docx b/sw/qa/extras/ooxmlexport/data/tdf118691.docx
new file mode 100644
index 000000000000..ce6c6c5cf76d
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/tdf118691.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
index df780afde73e..f32d14ee62a0 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
@@ -443,6 +443,18 @@ DECLARE_OOXMLIMPORT_TEST(testTdf104797, "tdf104797.docx")
CPPUNIT_ASSERT_EQUAL(false,getProperty<bool>(getRun(getParagraph(2), 5), "IsStart"));
}
+DECLARE_OOXMLEXPORT_TEST(testTdf118691, "tdf118691.docx")
+{
+ uno::Reference<text::XTextTablesSupplier> xTablesSupplier(mxComponent, uno::UNO_QUERY);
+ uno::Reference<container::XIndexAccess> xTables(xTablesSupplier->getTextTables(),
+ uno::UNO_QUERY);
+ // Text "Before" stays in the first cell, not removed before the table because of
+ // bad handling of <w:cr>
+ uno::Reference<text::XTextTable> xTable(xTables->getByIndex(0), uno::UNO_QUERY);
+ uno::Reference<text::XTextRange> xCell(xTable->getCellByName("A1"), uno::UNO_QUERY);
+ CPPUNIT_ASSERT_EQUAL(OUString("Before\nAfter"), xCell->getString());
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */