diff options
author | László Németh <nemeth@numbertext.org> | 2018-09-21 12:38:48 +0200 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2018-09-22 15:47:11 +0200 |
commit | bdade7e3fc33c1832c6f6a472443fca8238738d2 (patch) | |
tree | 5126a7c8afa18f61cf320556402d91e63f9cf31d /sw/qa | |
parent | b56ad4cbe0aa67b92211cf31d70eca0b35c62666 (diff) |
tdf#105444 DOCX import: don't put extra paragraphs in comments
on Win32, waiting only for \r\n instead of \n in RemoveLastParagraph().
Change-Id: I8921a6a72e8397ed04edb9f339ba3f0bf5bbb98b
Reviewed-on: https://gerrit.libreoffice.org/60865
Tested-by: Jenkins
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sw/qa')
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/tdf105444.docx | bin | 0 -> 4928 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport12.cxx | 9 | ||||
-rw-r--r-- | sw/qa/extras/uiwriter/uiwriter.cxx | 10 |
3 files changed, 10 insertions, 9 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf105444.docx b/sw/qa/extras/ooxmlexport/data/tdf105444.docx Binary files differnew file mode 100644 index 000000000000..a6e0ea8732e3 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/tdf105444.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport12.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport12.cxx index 61388952f583..2b55c3f1ecfd 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport12.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport12.cxx @@ -797,6 +797,15 @@ DECLARE_OOXMLEXPORT_TEST(testTdf119143, "tdf119143.docx") sParaText); } +DECLARE_OOXMLEXPORT_TEST(testTdf105444, "tdf105444.docx") +{ + xmlDocPtr pXmlComm = parseExport("word/comments.xml"); + if (!pXmlComm) + return; + // there is no extra paragraph on Win32, only a single one. + assertXPath(pXmlComm, "/w:comments/w:comment/w:p", 1); +} + CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/qa/extras/uiwriter/uiwriter.cxx b/sw/qa/extras/uiwriter/uiwriter.cxx index 0bb8c12afab1..12c3e08cb150 100644 --- a/sw/qa/extras/uiwriter/uiwriter.cxx +++ b/sw/qa/extras/uiwriter/uiwriter.cxx @@ -5405,15 +5405,7 @@ void SwUiWriterTest::testCreateDocxAnnotation() uno::Reference<beans::XPropertySet> xField(xFields->nextElement(), uno::UNO_QUERY); // this was empty instead of "some text" - OUString aResultText = aSomeText -#ifdef WNT - // FIXME From some unclear reason, on windows we get an additional - // paragraph in the comment - please adapt this test when that gets - // fixed. - + "\n" -#endif - ; - CPPUNIT_ASSERT_EQUAL(aResultText, xField->getPropertyValue("Content").get<OUString>()); + CPPUNIT_ASSERT_EQUAL(aSomeText, xField->getPropertyValue("Content").get<OUString>()); } void SwUiWriterTest::testTdf107976() |