From adc10e62ddc4a65f6b1fecbcfc7c6560489e3aaa Mon Sep 17 00:00:00 2001 From: Miklos Vajna Date: Wed, 11 Apr 2018 11:51:12 +0200 Subject: sw XHTML export: fix missing namespace prefix of lists Unordered lists, but fixes ordered lists as a side effect, too. Change-Id: I1752522e906975b112e6938ffc5456e53a165996 Reviewed-on: https://gerrit.libreoffice.org/52724 Reviewed-by: Miklos Vajna Tested-by: Jenkins --- sw/qa/extras/htmlexport/data/reqif-list.xhtml | 11 +++++++++++ sw/qa/extras/htmlexport/htmlexport.cxx | 12 ++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 sw/qa/extras/htmlexport/data/reqif-list.xhtml (limited to 'sw/qa') diff --git a/sw/qa/extras/htmlexport/data/reqif-list.xhtml b/sw/qa/extras/htmlexport/data/reqif-list.xhtml new file mode 100644 index 000000000000..5433ee10a6ea --- /dev/null +++ b/sw/qa/extras/htmlexport/data/reqif-list.xhtml @@ -0,0 +1,11 @@ +Heading + + + First + + Second + + Third + + + diff --git a/sw/qa/extras/htmlexport/htmlexport.cxx b/sw/qa/extras/htmlexport/htmlexport.cxx index 7f10e4befa90..6eb45ff90882 100644 --- a/sw/qa/extras/htmlexport/htmlexport.cxx +++ b/sw/qa/extras/htmlexport/htmlexport.cxx @@ -478,6 +478,18 @@ DECLARE_HTMLEXPORT_TEST(testReqIfTable, "reqif-table.xhtml") assertXPathNoAttribute(pDoc, "/html/body/div/table/tr/th", "bgcolor"); } +DECLARE_HTMLEXPORT_TEST(testReqIfList, "reqif-list.xhtml") +{ + SvStream* pStream = maTempFile.GetStream(StreamMode::READ); + CPPUNIT_ASSERT(pStream); + pStream->Seek(STREAM_SEEK_TO_END); + sal_uInt64 nLength = pStream->Tell(); + pStream->Seek(0); + OString aStream(read_uInt8s_ToOString(*pStream, nLength)); + // This failed,
    was written. + CPPUNIT_ASSERT(aStream.indexOf("") != -1); +} + DECLARE_HTMLEXPORT_ROUNDTRIP_TEST(testReqIfOle2, "reqif-ole2.xhtml") { uno::Reference xSupplier(mxComponent, uno::UNO_QUERY); -- cgit