diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2024-05-13 08:37:22 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2024-05-13 12:15:08 +0200 |
commit | 9c7acbc937b3b341c10187b837e09cc20399f04e (patch) | |
tree | 029882ab00b21ac4316d8e54def4614af1a75329 | |
parent | 4e5040dc44024f8313ca51627b6871675865cdf6 (diff) |
tdf#160984 sw continuous endnotes: fix CppunitTest_sw_layoutwriter3
These are similar to commit ab3416cad1dd4e706432f9b1a3592cec823c76b0
(tdf#160984 sw continuous endnotes: fix
testContinuousEndnotesMoveBackwards, 2024-05-10).
I've manually verified that the use-case still works as intended, so fix
the failing tests by relaxing the assert a bit: now we accept endnotes
directly under the page frame or under the column frame as well.
This way these tests won't break when we switch to section-based
continuous endnotes.
Change-Id: Ib98d6277534cc2e934595f19927836744eec64d5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167567
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
-rw-r--r-- | sw/qa/extras/layout/layout3.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sw/qa/extras/layout/layout3.cxx b/sw/qa/extras/layout/layout3.cxx index e907f6bc8ebf..329c81847313 100644 --- a/sw/qa/extras/layout/layout3.cxx +++ b/sw/qa/extras/layout/layout3.cxx @@ -1444,7 +1444,7 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testTdf124601) // i.e. there was a separate endnote page, even when the ContinuousEndnotes compat option was // on. assertXPath(pXmlDoc, "/root/page"_ostr, 2); - assertXPath(pXmlDoc, "/root/page[2]/ftncont"_ostr, 1); + assertXPath(pXmlDoc, "/root/page[2]//ftncont"_ostr, 1); } CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testTdf124601b) @@ -1554,7 +1554,7 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testContinuousEndnotesInsertPageAtStart) // - Expected: 1 // - Actual : 0 // i.e. the footnote container remained on page 2. - assertXPath(pXmlDoc, "/root/page[3]/ftncont"_ostr, 1); + assertXPath(pXmlDoc, "/root/page[3]//ftncont"_ostr, 1); } CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testContinuousEndnotesDeletePageAtStart) @@ -1581,7 +1581,7 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testContinuousEndnotesDeletePageAtStart) // - Actual : 2 // i.e. the endnote remained on an (otherwise) empty 2nd page. assertXPath(pXmlDoc, "/root/page"_ostr, 1); - assertXPath(pXmlDoc, "/root/page[1]/ftncont"_ostr, 1); + assertXPath(pXmlDoc, "/root/page[1]//ftncont"_ostr, 1); } CPPUNIT_TEST_FIXTURE(SwLayoutWriter3, testTdf128399) |