summaryrefslogtreecommitdiff
path: root/sw/qa/extras/layout
diff options
context:
space:
mode:
authorPatrick Jaap <patrick.jaap@tu-dresden.de>2019-01-23 10:01:36 +0100
committerMiklos Vajna <vmiklos@collabora.com>2019-02-05 14:55:01 +0100
commit8e3afdb5989d571410350f1d43fcf26492a4eaff (patch)
tree047640fa43cd7b491a984612591c22aa229d9fc4 /sw/qa/extras/layout
parent8a7a93b3f24b95bfcffc25e58f9e43c7be4cc1f1 (diff)
tdf#122878: enable wrap for flys in footer
This patch removes the check for a footer node, intoduced by 23f698ecee033612ac3a9f5cfd7674b08bb3ccd1 preserving the behaviour for the connected bug reports i13832 and i24135. Without this check, the wraping becomes enabled for footer objects, too. With this enhencement, the commits 7df33caac85ac90c26e97dedbc201f46dc9e4cb4 d3db6ff43a531ecf1afc858a0a8832353d091644 are directly affected and therefore the unit test is edited. Change-Id: I093add9e251ac97859a66cb8b8563010ef734c2d Reviewed-on: https://gerrit.libreoffice.org/67069 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'sw/qa/extras/layout')
-rw-r--r--sw/qa/extras/layout/data/tdf116989.docxbin15538 -> 0 bytes
-rw-r--r--sw/qa/extras/layout/data/tdf122878.docxbin0 -> 17740 bytes
-rw-r--r--sw/qa/extras/layout/layout.cxx14
3 files changed, 7 insertions, 7 deletions
diff --git a/sw/qa/extras/layout/data/tdf116989.docx b/sw/qa/extras/layout/data/tdf116989.docx
deleted file mode 100644
index 498b60dbf345..000000000000
--- a/sw/qa/extras/layout/data/tdf116989.docx
+++ /dev/null
Binary files differ
diff --git a/sw/qa/extras/layout/data/tdf122878.docx b/sw/qa/extras/layout/data/tdf122878.docx
new file mode 100644
index 000000000000..f42e92ea2641
--- /dev/null
+++ b/sw/qa/extras/layout/data/tdf122878.docx
Binary files differ
diff --git a/sw/qa/extras/layout/layout.cxx b/sw/qa/extras/layout/layout.cxx
index 99ca36673c71..83af848df67f 100644
--- a/sw/qa/extras/layout/layout.cxx
+++ b/sw/qa/extras/layout/layout.cxx
@@ -64,7 +64,7 @@ public:
void testTdf120287();
void testTdf120287b();
void testTdf120287c();
- void testTdf116989();
+ void testTdf122878();
void testTdf115094();
CPPUNIT_TEST_SUITE(SwLayoutWriter);
@@ -103,7 +103,7 @@ public:
CPPUNIT_TEST(testTdf120287);
CPPUNIT_TEST(testTdf120287b);
CPPUNIT_TEST(testTdf120287c);
- CPPUNIT_TEST(testTdf116989);
+ CPPUNIT_TEST(testTdf122878);
CPPUNIT_TEST(testTdf115094);
CPPUNIT_TEST_SUITE_END();
@@ -2718,17 +2718,17 @@ void SwLayoutWriter::testTdf120287c()
assertXPath(pXmlDoc, "/root/page/body/txt[1]/LineBreak", 3);
}
-void SwLayoutWriter::testTdf116989()
+void SwLayoutWriter::testTdf122878()
{
- createDoc("tdf116989.docx");
+ createDoc("tdf122878.docx");
xmlDocPtr pXmlDoc = parseLayoutDump();
// FIXME: the XPath should be adjusted when the proper floating table would be imported
const sal_Int32 nTblTop
- = getXPath(pXmlDoc, "/root/page[1]/footer/tab/infos/bounds", "top").toInt32();
+ = getXPath(pXmlDoc, "/root/page[1]/footer/txt/anchored/fly/tab/infos/bounds", "top")
+ .toInt32();
const sal_Int32 nFirstPageParaCount
= getXPathContent(pXmlDoc, "count(/root/page[1]/body/txt)").toInt32();
- // FIXME: should be exactly 30, when proper floating tables in footers are supported
- CPPUNIT_ASSERT_GREATEREQUAL(sal_Int32(30), nFirstPageParaCount);
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(30), nFirstPageParaCount);
for (sal_Int32 i = 1; i <= nFirstPageParaCount; ++i)
{
const OString xPath = "/root/page[1]/body/txt[" + OString::number(i) + "]/infos/bounds";