[Libreoffice-commits] core.git: sw/qa

Xisco Fauli (via logerrit) logerrit at kemper.freedesktop.org
Sun Aug 15 23:42:57 UTC 2021


 sw/qa/extras/htmlexport/data/tdf132739.odt |binary
 sw/qa/extras/htmlexport/htmlexport.cxx     |   12 ++++++++++++
 2 files changed, 12 insertions(+)

New commits:
commit 5aac78e5fb241050a86714687e9ff8804588ae3c
Author:     Xisco Fauli <xiscofauli at libreoffice.org>
AuthorDate: Sun Aug 15 19:09:59 2021 +0200
Commit:     Xisco Fauli <xiscofauli at libreoffice.org>
CommitDate: Mon Aug 16 01:42:23 2021 +0200

    tdf#132739: sw_htmlexport: Add unittest
    
    Change-Id: I69a5b0659d8b9a13b662ee1e7612e056f9d3ce4d
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120512
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>

diff --git a/sw/qa/extras/htmlexport/data/tdf132739.odt b/sw/qa/extras/htmlexport/data/tdf132739.odt
new file mode 100644
index 000000000000..6156aca93bd0
Binary files /dev/null and b/sw/qa/extras/htmlexport/data/tdf132739.odt differ
diff --git a/sw/qa/extras/htmlexport/htmlexport.cxx b/sw/qa/extras/htmlexport/htmlexport.cxx
index e58641ac6f8a..cd680b1ad12b 100644
--- a/sw/qa/extras/htmlexport/htmlexport.cxx
+++ b/sw/qa/extras/htmlexport/htmlexport.cxx
@@ -1021,6 +1021,18 @@ DECLARE_HTMLEXPORT_TEST(testFieldShade, "field-shade.odt")
     assertXPath(pDoc, "/html/body/p[2]/span/span", 0);
 }
 
+DECLARE_HTMLEXPORT_TEST(testTdf132739, "tdf132739.odt")
+{
+    htmlDocUniquePtr pDoc = parseHtml(maTempFile);
+    CPPUNIT_ASSERT(pDoc);
+
+    // Without the fix in place, this test would have failed with
+    // - Expected: background: #5983b0; border: 1px solid #333333; padding: 0.04in
+    // - Actual  : background: #5983b0
+    assertXPath(pDoc, "/html/body/table/tr[1]/td", "style",
+                "background: #5983b0; border: 1px solid #333333; padding: 0.04in");
+}
+
 DECLARE_HTMLEXPORT_TEST(testFieldShadeReqIf, "field-shade-reqif.odt")
 {
     htmlDocUniquePtr pDoc = parseHtml(maTempFile);


More information about the Libreoffice-commits mailing list