diff options
Diffstat (limited to 'sw/qa/extras/layout/layout2.cxx')
-rw-r--r-- | sw/qa/extras/layout/layout2.cxx | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/sw/qa/extras/layout/layout2.cxx b/sw/qa/extras/layout/layout2.cxx index 9daa260c21c4..e9654dc7c9b6 100644 --- a/sw/qa/extras/layout/layout2.cxx +++ b/sw/qa/extras/layout/layout2.cxx @@ -973,6 +973,24 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter2, testChangedTableRows) assertXPath(pXmlDoc, "/metafile/push/push/push/push/push/fillcolor[@color='#3faf46']", 1); } +CPPUNIT_TEST_FIXTURE(SwLayoutWriter2, testTdf155187_TableInTextChange) +{ + createSwDoc("table_in_text_change.fodt"); + SwDoc* pDoc = getSwDoc(); + SwDocShell* pShell = pDoc->GetDocShell(); + + // Dump the rendering of the first page as an XML file. + std::shared_ptr<GDIMetaFile> xMetaFile = pShell->GetPreviewMetaFile(); + MetafileXmlDump dumper; + xmlDocUniquePtr pXmlDoc = dumpAndParse(dumper, *xMetaFile); + CPPUNIT_ASSERT(pXmlDoc); + + // This was 0 (other color, not COL_AUTHOR_TABLE_DEL, color of the tracked row deletion) + assertXPath(pXmlDoc, "/metafile/push/push/push/push/push/fillcolor[@color='#fce6f4']", 2); + // This was 0 (other color, not COL_AUTHOR_TABLE_INS, color of the tracked row insertion) + assertXPath(pXmlDoc, "/metafile/push/push/push/push/push/fillcolor[@color='#e1f2fa']", 2); +} + CPPUNIT_TEST_FIXTURE(SwLayoutWriter2, testTdf145225_RedlineMovingWithBadInsertion) { createSwDoc("tdf42748.fodt"); |