From 5a989074cd1f8afdc03d0ee4f2dc12b174f9aa19 Mon Sep 17 00:00:00 2001 From: Xisco Fauli Date: Mon, 3 Feb 2020 13:09:06 +0100 Subject: [PATCH] tdf#129993: Add unittest MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I30b0583a3e38f0f8a06a7711c9413101dc87cc21 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87861 Tested-by: Jenkins Reviewed-by: Xisco FaulĂ­ Reviewed-by: Miklos Vajna --- .../CppunitTest_lotuswordpro_import_test.mk | 37 +++++++++ lotuswordpro/Module_lotuswordpro.mk | 1 + lotuswordpro/qa/cppunit/data/tdf129993.lwp | Bin 0 -> 26152 bytes lotuswordpro/qa/cppunit/import_test.cxx | 73 ++++++++++++++++++ 4 files changed, 111 insertions(+) create mode 100644 lotuswordpro/CppunitTest_lotuswordpro_import_test.mk create mode 100644 lotuswordpro/qa/cppunit/data/tdf129993.lwp create mode 100644 lotuswordpro/qa/cppunit/import_test.cxx diff --git a/lotuswordpro/CppunitTest_lotuswordpro_import_test.mk b/lotuswordpro/CppunitTest_lotuswordpro_import_test.mk new file mode 100644 index 000000000000..325b1db2b921 --- /dev/null +++ b/lotuswordpro/CppunitTest_lotuswordpro_import_test.mk @@ -0,0 +1,37 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_CppunitTest_CppunitTest,lotuswordpro_import_test)) + +$(eval $(call gb_CppunitTest_use_external,lotuswordpro_import_test,boost_headers)) + +$(eval $(call gb_CppunitTest_add_exception_objects,lotuswordpro_import_test, \ + lotuswordpro/qa/cppunit/import_test \ +)) + +$(eval $(call gb_CppunitTest_use_libraries,lotuswordpro_import_test, \ + comphelper \ + cppu \ + cppuhelper \ + sal \ + test \ + unotest \ + vcl \ +)) + +$(eval $(call gb_CppunitTest_use_sdk_api,lotuswordpro_import_test)) + +$(eval $(call gb_CppunitTest_use_ure,lotuswordpro_import_test)) +$(eval $(call gb_CppunitTest_use_vcl,lotuswordpro_import_test)) + +$(eval $(call gb_CppunitTest_use_rdb,lotuswordpro_import_test,services)) + +$(eval $(call gb_CppunitTest_use_configuration,lotuswordpro_import_test)) + +# vim: set noet sw=4 ts=4: diff --git a/lotuswordpro/Module_lotuswordpro.mk b/lotuswordpro/Module_lotuswordpro.mk index 538702e72bef..d7be4232161a 100644 --- a/lotuswordpro/Module_lotuswordpro.mk +++ b/lotuswordpro/Module_lotuswordpro.mk @@ -17,6 +17,7 @@ $(eval $(call gb_Module_add_targets,lotuswordpro,\ $(eval $(call gb_Module_add_check_targets,lotuswordpro,\ CppunitTest_lotuswordpro_test_lotuswordpro \ + CppunitTest_lotuswordpro_import_test \ )) endif diff --git a/lotuswordpro/qa/cppunit/data/tdf129993.lwp b/lotuswordpro/qa/cppunit/data/tdf129993.lwp new file mode 100644 index 0000000000000000000000000000000000000000..54bc9ac99891922f8e4fb644ebcb0f3c90c2c22e GIT binary patch literal 26152 zcmb__33yb;m2NG)YL}4MmkS01Mqmj^?3i0Z5?um8YXf9s=tgRwjnEEAb{yISJ79zD z*u-maWCw4tV`mvJapJfeJF$~^Cdr#6i6+tt=lf>VqZT{tnu=N|qp9(DjP=VMliz;l#=n2*?b__H_#C59|-mN93~UZ4L%mopC0C)oE2p~+?;7n|5EE_xwW>bS!~+X z+#s4-8botTZPTvW8ria?33#>54XV`JxyjV0cg~#LsHdkxF%CFPd~}SDF)llX=efygx{$Eh z#W4ydjr5x8T&9GUWqLL=cX#y*O?> zO$=8rTh^2B_zvz2;>hV`3;aIov*6o^n@JqGF*aSW`HdY+PUgkeBho>bBgQ8(5M~RB z2S}ABZTTxrRuNi291~*95bRpNulnJKIllMqF*LpTgy+ZDOu?3bp3m3&Q`0{$Dq^J4s_L62G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V?RPHND`{JBxC;> kv1%en6{lou46*r$og9y!UElDeucPnhSmM*7NmTm(0dYkIQ~&?~ literal 0 HcmV?d00001 diff --git a/lotuswordpro/qa/cppunit/import_test.cxx b/lotuswordpro/qa/cppunit/import_test.cxx new file mode 100644 index 000000000000..5f3770b69e3e --- /dev/null +++ b/lotuswordpro/qa/cppunit/import_test.cxx @@ -0,0 +1,73 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#include +#include + +#include +#include +#include +#include +#include + +#include + +using namespace ::com::sun::star; + +class LotusWordProTest : public test::BootstrapFixture, public unotest::MacrosTest +{ +public: + virtual void setUp() override; + + virtual void tearDown() override; + uno::Reference& getComponent() { return mxComponent; } + +private: + uno::Reference mxComponentContext; + uno::Reference mxComponent; +}; + +void LotusWordProTest::setUp() +{ + test::BootstrapFixture::setUp(); + + mxComponentContext.set(comphelper::getComponentContext(getMultiServiceFactory())); + mxDesktop.set(frame::Desktop::create(mxComponentContext)); +} + +void LotusWordProTest::tearDown() +{ + if (mxComponent.is()) + mxComponent->dispose(); + + test::BootstrapFixture::tearDown(); +} + +char const DATA_DIRECTORY[] = "/lotuswordpro/qa/cppunit/data/"; + +CPPUNIT_TEST_FIXTURE(LotusWordProTest, testTdf129993) +{ + OUString aURL = m_directories.getURLFromSrc(DATA_DIRECTORY) + "tdf129993.lwp"; + getComponent() = loadFromDesktop(aURL); + CPPUNIT_ASSERT(getComponent().is()); + + uno::Reference textDocument(getComponent(), uno::UNO_QUERY); + uno::Reference xParaEnumAccess(textDocument->getText(), + uno::UNO_QUERY); + uno::Reference xParaEnum = xParaEnumAccess->createEnumeration(); + for (int i = 0; i < 15; ++i) + xParaEnum->nextElement(); + uno::Reference xServiceInfo(xParaEnum->nextElement(), uno::UNO_QUERY); + + CPPUNIT_ASSERT_EQUAL(sal_True, xServiceInfo->supportsService("com.sun.star.text.TextTable")); +} + +CPPUNIT_PLUGIN_IMPLEMENT(); + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */