sw/qa/extras/ooxmlexport/data/tdf157598.docx |binary
 sw/qa/extras/ooxmlexport/ooxmlexport18.cxx   |   12 ++++++++++++
 2 files changed, 12 insertions(+)

New commits:
commit 98771c4a6da0e760b10983e66885fafcfe918d16
Author:     Xisco Fauli <xiscofa...@libreoffice.org>
AuthorDate: Thu Oct 5 10:13:46 2023 +0200
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Thu Oct 5 12:40:30 2023 +0200

    tdf#157598: sw_ooxmlexport18: Add unittest
    
    Change-Id: If17054cfc56c57dfe9eab5461973fb4c3035f218
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157584
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/sw/qa/extras/ooxmlexport/data/tdf157598.docx 
b/sw/qa/extras/ooxmlexport/data/tdf157598.docx
new file mode 100644
index 000000000000..7a5a2b15999b
Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf157598.docx differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
index bf7eb22eb270..066eb3647cb5 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
@@ -531,6 +531,18 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf148834_lineNumbering)
                 
"//w:style[@w:styleId='0NUMBERED']/w:pPr/w:suppressLineNumbers", "val", "0");
 }
 
+CPPUNIT_TEST_FIXTURE(Test, testTdf157598)
+{
+    loadAndSave("tdf157598.docx");
+
+    xmlDocUniquePtr pStylesXml = parseExport("word/styles.xml");
+
+    // Without the fix in place, this test would have failed with
+    // - Expected: 0
+    // - Actual  : 1
+    assertXPath(pStylesXml, "//w:style[@w:styleId='Normal']/w:rPr/w:rtl", 0);
+}
+
 CPPUNIT_TEST_FIXTURE(Test, testTdf76022_textboxWrap)
 {
     // Granted, this is an ODT with a bit of an anomaly - tables ignore fly 
wrapping.

Reply via email to