[Libreoffice-commits] core.git: sw/qa
Xisco Fauli (via logerrit)
logerrit at kemper.freedesktop.org
Tue Sep 8 15:58:41 UTC 2020
sw/qa/extras/ooxmlexport/ooxmlexport15.cxx | 21 +++------------------
sw/qa/extras/uiwriter/uiwriter3.cxx | 17 +++++++++++++++++
2 files changed, 20 insertions(+), 18 deletions(-)
New commits:
commit 09bd2fb3c3b35b61cbf99b5d95a9542b344c7251
Author: Xisco Fauli <xiscofauli at libreoffice.org>
AuthorDate: Tue Sep 8 13:38:17 2020 +0200
Commit: Xisco Fauli <xiscofauli at libreoffice.org>
CommitDate: Tue Sep 8 17:57:57 2020 +0200
sw_ooxmlexport15: DECLARE_OOXMLIMPORT_TEST -> DECLARE_OOXMLEXPORT_TEST
and move one test to sw_uiwriter. It fits more there
Change-Id: I335b83936f9570d18fe14be860cbc4818eaf0007
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102246
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli at libreoffice.org>
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
index 2b49b47dbfd2..999ef57a38af 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
@@ -47,7 +47,7 @@ DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testTdf123621, "tdf123621.docx")
"/wp:positionV/wp:posOffset", "1080135");
}
-DECLARE_OOXMLIMPORT_TEST(testTdf131801, "tdf131801.docx")
+DECLARE_OOXMLEXPORT_TEST(testTdf131801, "tdf131801.docx")
{
CPPUNIT_ASSERT_EQUAL(1, getPages());
@@ -503,7 +503,7 @@ DECLARE_OOXMLEXPORT_TEST(testTdf134063, "tdf134063.docx")
CPPUNIT_ASSERT_EQUAL(sal_Int32(720), getXPath(pDump, "//page[1]/body/txt[1]/Text[3]", "nWidth").toInt32());
}
-DECLARE_OOXMLIMPORT_TEST(TestTdf135653, "tdf135653.docx")
+DECLARE_OOXMLEXPORT_TEST(TestTdf135653, "tdf135653.docx")
{
uno::Reference<beans::XPropertySet> xOLEProps(getShape(1), uno::UNO_QUERY_THROW);
drawing::FillStyle nFillStyle = static_cast<drawing::FillStyle>(-1);
@@ -579,22 +579,7 @@ DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testRelativeAnchorHeightFromBottomMarginHasF
assertXPath(pXmlDoc, "//SwAnchoredDrawObject/bounds", "height", "1147");
}
-DECLARE_OOXMLIMPORT_TEST(TestTdf112342, "tdf112342.docx")
-{
- //Get the last para
- uno::Reference<text::XTextRange> xPara = getParagraph(3);
- auto xCur = xPara->getText()->createTextCursor();
- //Go to the end of it
- xCur->gotoEnd(false);
- //And let's remove the last 2 chars (the last para with its char).
- xCur->goLeft(2, true);
- xCur->setString("");
-
- //If the second paragraph on the second page, this will be passed.
- CPPUNIT_ASSERT_EQUAL_MESSAGE("Page break does not match", 2, getPages());
-}
-
-DECLARE_OOXMLIMPORT_TEST(TestTdf132483, "tdf132483.docx")
+DECLARE_OOXMLEXPORT_TEST(TestTdf132483, "tdf132483.docx")
{
uno::Reference<beans::XPropertySet> xOLEProps(getShape(1), uno::UNO_QUERY_THROW);
sal_Int16 nVRelPos = -1;
diff --git a/sw/qa/extras/ooxmlexport/data/tdf112342.docx b/sw/qa/extras/uiwriter/data3/tdf112342.docx
similarity index 100%
rename from sw/qa/extras/ooxmlexport/data/tdf112342.docx
rename to sw/qa/extras/uiwriter/data3/tdf112342.docx
diff --git a/sw/qa/extras/uiwriter/uiwriter3.cxx b/sw/qa/extras/uiwriter/uiwriter3.cxx
index 928711466229..46e5a4eee028 100644
--- a/sw/qa/extras/uiwriter/uiwriter3.cxx
+++ b/sw/qa/extras/uiwriter/uiwriter3.cxx
@@ -191,6 +191,23 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf134404)
CPPUNIT_ASSERT_EQUAL(2, getPages());
}
+CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf112342)
+{
+ load(DATA_DIRECTORY, "tdf112342.docx");
+
+ //Get the last para
+ uno::Reference<text::XTextRange> xPara = getParagraph(3);
+ auto xCur = xPara->getText()->createTextCursor();
+ //Go to the end of it
+ xCur->gotoEnd(false);
+ //And let's remove the last 2 chars (the last para with its char).
+ xCur->goLeft(2, true);
+ xCur->setString("");
+
+ //If the second paragraph on the second page, this will be passed.
+ CPPUNIT_ASSERT_EQUAL_MESSAGE("Page break does not match", 2, getPages());
+}
+
CPPUNIT_TEST_FIXTURE(SwUiWriterTest3, testTdf132321)
{
load(DATA_DIRECTORY, "tdf132321.odt");
More information about the Libreoffice-commits
mailing list