summaryrefslogtreecommitdiff
path: root/sw/qa/extras
diff options
context:
space:
mode:
Diffstat (limited to 'sw/qa/extras')
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf137466.docxbin0 -> 20243 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport17.cxx15
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport4.cxx2
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport5.cxx4
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlw14export.cxx2
5 files changed, 19 insertions, 4 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf137466.docx b/sw/qa/extras/ooxmlexport/data/tdf137466.docx
new file mode 100644
index 000000000000..3c5977251bda
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/tdf137466.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
index c711a6b2a10b..a7762a057e32 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport17.cxx
@@ -64,6 +64,21 @@ CPPUNIT_TEST_FIXTURE(Test, testParaStyleNumLevel)
assertXPath(pXmlDoc, "/w:styles/w:style[@w:styleId='Mystyle']/w:pPr/w:numPr/w:ilvl", "val", "1");
}
+DECLARE_OOXMLEXPORT_TEST(testTdf137466, "tdf137466.docx")
+{
+ xmlDocUniquePtr pXmlDoc = parseExport("word/document.xml");
+ if (!pXmlDoc)
+ return; // initial import, no futher checks
+
+ // Ensure that we have <w:placeholder><w:docPart v:val="xxxx"/></w:placeholder>
+ OUString sDocPart = getXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:placeholder/w:docPart", "val");
+ CPPUNIT_ASSERT_EQUAL(OUString("DefaultPlaceholder_-1854013440"), sDocPart);
+
+ // Ensure that we have <w15:color v:val="xxxx"/>
+ OUString sColor = getXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w15:color", "val");
+ CPPUNIT_ASSERT_EQUAL(OUString("FF0000"), sColor);
+}
+
CPPUNIT_TEST_FIXTURE(Test, testDontAddNewStyles)
{
// Given a document that lacks builtin styles, and addition of them is disabled:
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
index 5858eec46524..cfb779d13c84 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
@@ -1021,7 +1021,7 @@ CPPUNIT_TEST_FIXTURE(Test, testSimpleSdts)
xmlDocUniquePtr pXmlDoc = parseExport("word/document.xml");
assertXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:text", 1);
- assertXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:id", 3);
+ assertXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:id", 4);
assertXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:picture", 1);
assertXPath(pXmlDoc, "/w:document/w:body/w:sdt/w:sdtPr/w:group", 1);
assertXPath(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtPr/w:citation", 1);
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx
index 081ac3252d31..6b6c5c497b65 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport5.cxx
@@ -579,10 +579,10 @@ CPPUNIT_TEST_FIXTURE(Test, testFDO79062)
{
loadAndSave("fdo79062.docx");
xmlDocUniquePtr pXmlFootNotes = parseExport("word/footnotes.xml");
- assertXPath(pXmlFootNotes, "/w:footnotes", "Ignorable", "w14 wp14");
+ assertXPath(pXmlFootNotes, "/w:footnotes", "Ignorable", "w14 wp14 w15");
xmlDocUniquePtr pXmlEndNotes = parseExport("word/endnotes.xml");
- assertXPath(pXmlEndNotes, "/w:endnotes", "Ignorable", "w14 wp14");
+ assertXPath(pXmlEndNotes, "/w:endnotes", "Ignorable", "w14 wp14 w15");
//tdf#93121 don't add fake tabs in front of extra footnote paragraphs
uno::Reference<text::XFootnotesSupplier> xFootnoteSupp(mxComponent, uno::UNO_QUERY);
diff --git a/sw/qa/extras/ooxmlexport/ooxmlw14export.cxx b/sw/qa/extras/ooxmlexport/ooxmlw14export.cxx
index 157939060024..9e3184b566fe 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlw14export.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlw14export.cxx
@@ -248,7 +248,7 @@ DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(Test_McIgnorable, "TextEffects_StylisticSets
{
xmlDocUniquePtr pXmlDocument = parseExport("word/document.xml");
- assertXPath(pXmlDocument, "/w:document", "Ignorable", "w14 wp14");
+ assertXPath(pXmlDocument, "/w:document", "Ignorable", "w14 wp14 w15");
xmlDocUniquePtr pXmlStyles = parseExport("word/styles.xml");