diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-03-07 14:38:02 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-03-07 18:16:32 +0100 |
commit | b9086ccff6325bdfaf0cf03715fd8be7e2628169 (patch) | |
tree | f326a6a71a82755a103ffe3f2c22c44ff75f95d2 /sw/qa/extras/htmlimport | |
parent | c67d285a8b213816395948c2082faaf6bb6eab43 (diff) |
sw XHTML import: handle alt text of OLE objects
That ended up in the body text instead previously, which is unexpected.
Change-Id: Ia40d83b3243c313462dce2617404a0670a7debb2
Reviewed-on: https://gerrit.libreoffice.org/50897
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'sw/qa/extras/htmlimport')
-rw-r--r-- | sw/qa/extras/htmlimport/data/reqif-ole-img.xhtml | 2 | ||||
-rw-r--r-- | sw/qa/extras/htmlimport/htmlimport.cxx | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/sw/qa/extras/htmlimport/data/reqif-ole-img.xhtml b/sw/qa/extras/htmlimport/data/reqif-ole-img.xhtml index 05abc7721d24..b552783068ae 100644 --- a/sw/qa/extras/htmlimport/data/reqif-ole-img.xhtml +++ b/sw/qa/extras/htmlimport/data/reqif-ole-img.xhtml @@ -1,6 +1,6 @@ <reqif-xhtml:div><reqif-xhtml:br/> <reqif-xhtml:object data="reqif-ole-data.ole" type="text/rtf"> - <reqif-xhtml:object data="reqif-ole-img.png" type="image/png"/> + <reqif-xhtml:object data="reqif-ole-img.png" type="image/png">OLE Object</reqif-xhtml:object> </reqif-xhtml:object> </reqif-xhtml:div> diff --git a/sw/qa/extras/htmlimport/htmlimport.cxx b/sw/qa/extras/htmlimport/htmlimport.cxx index 23017e40a79b..079cc803b569 100644 --- a/sw/qa/extras/htmlimport/htmlimport.cxx +++ b/sw/qa/extras/htmlimport/htmlimport.cxx @@ -338,6 +338,9 @@ DECLARE_HTMLIMPORT_TEST(testReqIfOleImg, "reqif-ole-img.xhtml") = xStorage->openStreamElement(aStreamName, embed::ElementModes::READ); // This was empty. CPPUNIT_ASSERT_EQUAL(OUString("text/rtf"), getProperty<OUString>(xStream, "MediaType")); + + // Check alternate text (it was empty). + CPPUNIT_ASSERT_EQUAL(OUString("OLE Object"), getProperty<OUString>(xObject, "Title").trim()); } CPPUNIT_PLUGIN_IMPLEMENT(); |