diff options
author | Adam Co <rattles2013@gmail.com> | 2014-02-05 14:57:19 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-02-12 10:12:43 +0000 |
commit | 2eb142f4207f921dfeb6f9d5cd34cb0fb288bdd1 (patch) | |
tree | 211e38a4fe261aad44e9f9d99a57294fbc01b2cb | |
parent | 795e71626e2feeadef64e0535a14acf60ccb3b89 (diff) |
Add unit-tests for DOCX preservation of 'table cell redline'
Added unit-tests to make sure that 'table cell redlines'
(e.g. - table cell was inserted \ removed) are being round
tripped correctly from a DOCX file.
Change-Id: I773cb51a39654d2640200489d5199361b56396c7
Reviewed-on: https://gerrit.libreoffice.org/7878
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableCell.docx | bin | 0 -> 13744 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableCell.docx | bin | 0 -> 13842 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport.cxx | 16 |
3 files changed, 16 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableCell.docx b/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableCell.docx Binary files differnew file mode 100644 index 000000000000..c4d8394bf194 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/testTrackChangesDeletedTableCell.docx diff --git a/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableCell.docx b/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableCell.docx Binary files differnew file mode 100644 index 000000000000..d1450be67305 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/testTrackChangesInsertedTableCell.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx index a41f204022c9..2a4ee6eb3596 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx @@ -2309,6 +2309,22 @@ DECLARE_OOXMLEXPORT_TEST(testTrackChangesInsertedTableRow, "testTrackChangesInse assertXPath(pXmlDoc, "/w:document/w:body/w:tbl/w:tr[2]/w:trPr/w:ins"); } +DECLARE_OOXMLEXPORT_TEST(testTrackChangesDeletedTableCell, "testTrackChangesDeletedTableCell.docx") +{ + xmlDocPtr pXmlDoc = parseExport("word/document.xml"); + if (!pXmlDoc) + return; + assertXPath(pXmlDoc, "/w:document/w:body/w:tbl/w:tr[3]/w:tc/w:tcPr/w:cellDel"); +} + +DECLARE_OOXMLEXPORT_TEST(testTrackChangesInsertedTableCell, "testTrackChangesInsertedTableCell.docx") +{ + xmlDocPtr pXmlDoc = parseExport("word/document.xml"); + if (!pXmlDoc) + return; + assertXPath(pXmlDoc, "/w:document/w:body/w:tbl/w:tr[3]/w:tc/w:tcPr/w:cellIns"); +} + DECLARE_OOXMLEXPORT_TEST(testFdo69649, "fdo69649.docx") { // The DOCX containing the Table of Contents was not exported with correct page nos |