diff options
author | Xisco Fauli <xiscofauli@libreoffice.org> | 2021-11-03 10:48:34 +0100 |
---|---|---|
committer | Xisco Fauli <xiscofauli@libreoffice.org> | 2021-11-03 11:54:39 +0100 |
commit | 7ab9d4caddcf3e2b4e1f5541ebd85f4559bff615 (patch) | |
tree | e97ec6822ddec81bcf8487d5bd9c7e18d9f16e3c | |
parent | 5c47f33a640816ef1859e6f3b53aaafcdbce5e5c (diff) |
tdf#145361: sw_xhtmlexport: Add unittest
Change-Id: I4bbbdfa71f69ae2659922dce4b7445bcadc7d73a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124636
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
-rw-r--r-- | sw/qa/extras/htmlexport/xhtmlexport.cxx | 12 | ||||
-rw-r--r-- | sw/qa/extras/odfexport/data/tdf145361.odt | bin | 0 -> 9513 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 17efc1607b57..b03f184818fd 100644 --- a/sw/qa/extras/htmlexport/xhtmlexport.cxx +++ b/sw/qa/extras/htmlexport/xhtmlexport.cxx @@ -70,6 +70,18 @@ DECLARE_HTMLEXPORT_TEST(testTdf118637, "tdf118637.odt") != -1); } +DECLARE_HTMLEXPORT_TEST(testTdf145361, "tdf145361.odt") +{ + // Without the fix in place, this test would have failed with + // - SfxBaseModel::impl_store <file:///tmp/lu66091ameq.tmp> failed: 0xc10(Error Area:Io Class:Write Code:16) + 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("List entry has<br/><span style=\"margin-left:0cm\"/>a line break") != -1); +} + DECLARE_HTMLEXPORT_TEST(testTdf142483, "tdf142483.odt") { SvStream* pStream = maTempFile.GetStream(StreamMode::READ); diff --git a/sw/qa/extras/odfexport/data/tdf145361.odt b/sw/qa/extras/odfexport/data/tdf145361.odt Binary files differnew file mode 100644 index 000000000000..e5a6a03c9c9c --- /dev/null +++ b/sw/qa/extras/odfexport/data/tdf145361.odt |