summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Jaap <patrick.jaap@tu-dresden.de>2018-09-12 13:19:31 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2018-09-14 17:42:24 +0200
commit4ac31078b9c46231f8ecf0409a1724749ac8c5a4 (patch)
tree6fc8b7c8b8eacfca3dafe78c3d7d231bbfc9f9e5
parent18aeaa2ad9606483da9a78d91cf6270848641381 (diff)
tdf#117187 unit test
A unit test to conserve the current behavior which fixes 117187 partly. Change-Id: If10feb7de52963db2f6974581cac54fd1ae7e0e6 Reviewed-on: https://gerrit.libreoffice.org/60319 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r--sw/qa/extras/layout/data/tdf117187.odtbin0 -> 9673 bytes
-rw-r--r--sw/qa/extras/layout/layout.cxx11
2 files changed, 11 insertions, 0 deletions
diff --git a/sw/qa/extras/layout/data/tdf117187.odt b/sw/qa/extras/layout/data/tdf117187.odt
new file mode 100644
index 000000000000..b0aa59853350
--- /dev/null
+++ b/sw/qa/extras/layout/data/tdf117187.odt
Binary files differ
diff --git a/sw/qa/extras/layout/layout.cxx b/sw/qa/extras/layout/layout.cxx
index facc0fea1f6b..2e172660ebd2 100644
--- a/sw/qa/extras/layout/layout.cxx
+++ b/sw/qa/extras/layout/layout.cxx
@@ -36,6 +36,7 @@ public:
void testForcepoint72();
void testTdf118058();
void testTdf117188();
+ void testTdf117187();
CPPUNIT_TEST_SUITE(SwLayoutWriter);
CPPUNIT_TEST(testTdf116830);
@@ -54,6 +55,7 @@ public:
CPPUNIT_TEST(testForcepoint72);
CPPUNIT_TEST(testTdf118058);
CPPUNIT_TEST(testTdf117188);
+ CPPUNIT_TEST(testTdf117187);
CPPUNIT_TEST_SUITE_END();
private:
@@ -330,6 +332,15 @@ void SwLayoutWriter::testTdf117188()
assertXPath(pXmlDoc, "/root/page/body/txt/anchored/fly/infos/prtBounds", "height", sHeight);
}
+void SwLayoutWriter::testTdf117187()
+{
+ createDoc("tdf117187.odt");
+ xmlDocPtr pXmlDoc = parseLayoutDump();
+
+ // there should be no fly portions
+ assertXPath(pXmlDoc, "/root/page/body/txt/Special[@nType='POR_FLY']", 0);
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(SwLayoutWriter);
CPPUNIT_PLUGIN_IMPLEMENT();