summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2020-04-16 14:14:26 +0200
committerXisco Faulí <xiscofauli@libreoffice.org>2020-04-16 15:43:54 +0200
commitf2039cdbd827d60b8e0dbfa2e1d02dbb276514d6 (patch)
treeb320a7df195b60bf551eed49e51ea4451aad137e
parentacedbb8692bc84c93114dc4d441b3eb20b3ac467 (diff)
tdf#66305: xhtml: Add unittest
Change-Id: Iea9d1c5972534eb7fef17464fda88f559e9a75f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92365 Tested-by: Jenkins Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org>
-rw-r--r--sw/qa/extras/htmlexport/xhtmlexport.cxx12
-rw-r--r--sw/qa/extras/odfexport/data/tdf66305.odtbin0 -> 12685 bytes
2 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/extras/htmlexport/xhtmlexport.cxx b/sw/qa/extras/htmlexport/xhtmlexport.cxx
index 714c9825d759..1fdb1fd2cfee 100644
--- a/sw/qa/extras/htmlexport/xhtmlexport.cxx
+++ b/sw/qa/extras/htmlexport/xhtmlexport.cxx
@@ -79,6 +79,18 @@ DECLARE_HTMLEXPORT_TEST(testTdf107696, "tdf107696.odt")
!= -1);
}
+DECLARE_HTMLEXPORT_TEST(testTdf66305, "tdf66305.odt")
+{
+ SvStream* pStream = maTempFile.GetStream(StreamMode::READ);
+ CPPUNIT_ASSERT(pStream);
+ sal_uInt64 nLength = pStream->TellEnd();
+ OString aStream(read_uInt8s_ToOString(*pStream, nLength));
+ CPPUNIT_ASSERT(
+ aStream.indexOf("<p class=\"P6\"><a href=\"#__RefHeading__82004_486970805\" "
+ "class=\"Internet_20_link\">Introduction</a></p><p class=\"P7\"> </p>")
+ != -1);
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/qa/extras/odfexport/data/tdf66305.odt b/sw/qa/extras/odfexport/data/tdf66305.odt
new file mode 100644
index 000000000000..4a310a83d4e4
--- /dev/null
+++ b/sw/qa/extras/odfexport/data/tdf66305.odt
Binary files differ