summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorAdam Co <rattles2013@gmail.com>2014-02-04 15:02:08 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2014-02-12 09:00:14 +0000
commit89959563022ff2385d80ff481bbeed21b86f9c2c (patch)
treed8a922210bcc1b2088baf498cd1111984b485174 /sw
parent49dde4cd421181021e2d211514788b495b94c95b (diff)
Add unit-tests for DOCX preservation of 'table row redline'
Added unit-tests to make sure that 'table row redlines' (e.g. - table row was inserted \ removed) are being round tripped correctly from a DOCX file. Change-Id: I369dd32e7372d0cf0add19197f07d0ad604e9ef0 Reviewed-on: https://gerrit.libreoffice.org/7849 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableRow.docxbin0 -> 16518 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableRow.docxbin0 -> 16290 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport.cxx16
3 files changed, 16 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableRow.docx b/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableRow.docx
new file mode 100644
index 000000000000..71c499878615
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableRow.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableRow.docx b/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableRow.docx
new file mode 100644
index 000000000000..a7c0f56ed690
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableRow.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
index 232c6e8b88f1..a41f204022c9 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx
@@ -2293,6 +2293,22 @@ DECLARE_OOXMLEXPORT_TEST(testTrackChangesInsertedParagraphMark, "testTrackChange
assertXPath(pXmlDoc, "/w:document/w:body/w:p[1]/w:pPr/w:rPr/w:ins");
}
+DECLARE_OOXMLEXPORT_TEST(testTrackChangesDeletedTableRow, "testTrackChangesDeletedTableRow.docx")
+{
+ xmlDocPtr pXmlDoc = parseExport("word/document.xml");
+ if (!pXmlDoc)
+ return;
+ assertXPath(pXmlDoc, "/w:document/w:body/w:tbl/w:tr[2]/w:trPr/w:del");
+}
+
+DECLARE_OOXMLEXPORT_TEST(testTrackChangesInsertedTableRow, "testTrackChangesInsertedTableRow.docx")
+{
+ xmlDocPtr pXmlDoc = parseExport("word/document.xml");
+ if (!pXmlDoc)
+ return;
+ assertXPath(pXmlDoc, "/w:document/w:body/w:tbl/w:tr[2]/w:trPr/w:ins");
+}
+
DECLARE_OOXMLEXPORT_TEST(testFdo69649, "fdo69649.docx")
{
// The DOCX containing the Table of Contents was not exported with correct page nos