Kaydet (Commit) c7e5c7da authored tarafından Jens Carl's avatar Jens Carl

tdf#45904 Move _XDataPilotTablesSupplier Java test to C++

Change-Id: Iaea5b7abc0a289035c7a230c0034d2422cc4ae5f
Reviewed-on: https://gerrit.libreoffice.org/46001Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarJens Carl <j.carl43@gmx.de>
üst e5a3f125
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
/*
* 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/.
*/
#ifndef INCLUDED_TEST_SHEET_XDATAPILOTTABLESSUPPLIER_HXX
#define INCLUDED_TEST_SHEET_XDATAPILOTTABLESSUPPLIER_HXX
#include <com/sun/star/uno/XInterface.hpp>
#include <com/sun/star/uno/Reference.hxx>
#include <test/testdllapi.hxx>
namespace apitest
{
class OOO_DLLPUBLIC_TEST XDataPilotTablesSupplier
{
public:
virtual css::uno::Reference<css::uno::XInterface> init() = 0;
void testGetDataPilotTables();
protected:
~XDataPilotTablesSupplier() {}
};
}
#endif // INCLUDED_TEST_SHEET_XDATAPILOTTABLESSUPPLIER_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
......@@ -598,7 +598,6 @@ $(eval $(call gb_Jar_add_sourcefiles,OOoRunner,\
qadevOOo/tests/java/ifc/sheet/_XDatabaseRanges \
qadevOOo/tests/java/ifc/sheet/_XDataPilotField \
qadevOOo/tests/java/ifc/sheet/_XDataPilotTables \
qadevOOo/tests/java/ifc/sheet/_XDataPilotTablesSupplier \
qadevOOo/tests/java/ifc/sheet/_XDDELink \
qadevOOo/tests/java/ifc/sheet/_XDocumentAuditing \
qadevOOo/tests/java/ifc/sheet/_XEnhancedMouseClickBroadcaster \
......
......@@ -231,7 +231,6 @@
"ScTableSheetObj";"com::sun::star::chart::XChartDataArray";"setRowDescriptions()"
"ScTableSheetObj";"com::sun::star::chart::XChartDataArray";"getColumnDescriptions()"
"ScTableSheetObj";"com::sun::star::chart::XChartDataArray";"setColumnDescriptions()"
"ScTableSheetObj";"com::sun::star::sheet::XDataPilotTablesSupplier";"getDataPilotTables()"
"ScTableSheetObj";"com::sun::star::sheet::XCellFormatRangesSupplier";"getCellFormatRanges()"
"ScTableSheetObj";"com::sun::star::util::XModifyBroadcaster#optional";"addModifyListener()"
"ScTableSheetObj";"com::sun::star::util::XModifyBroadcaster#optional";"removeModifyListener()"
......
/*
* 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/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
package ifc.sheet;
import lib.MultiMethodTest;
import com.sun.star.sheet.XDataPilotTables;
import com.sun.star.sheet.XDataPilotTablesSupplier;
/**
* Testing <code>com.sun.star.sheet.XDataPilotTablesSupplier</code>
* interface methods :
* <ul>
* <li><code> getDataPilotTables()</code></li>
* </ul> <p>
* @see com.sun.star.sheet.XDataPilotTablesSupplier
*/
public class _XDataPilotTablesSupplier extends MultiMethodTest {
public XDataPilotTablesSupplier oObj = null;
/**
* Test calls the method and checks returned value. <p>
* Has <b> OK </b> status if returned value isn't null
* and no exceptions were thrown. <p>
*/
public void _getDataPilotTables() {
XDataPilotTables DPTables = oObj.getDataPilotTables();
tRes.tested("getDataPilotTables()", DPTables != null);
}
} // EOC _XDataPilotTablesSupplier
......@@ -9,6 +9,7 @@
#include <test/calc_unoapi_test.hxx>
#include <test/sheet/xcellseries.hxx>
#include <test/sheet/xdatapilottablessupplier.hxx>
#include <test/sheet/xmultipleoperation.hxx>
#include <test/sheet/xprintareas.hxx>
#include <test/sheet/xscenarioenhanced.hxx>
......@@ -38,9 +39,10 @@ using namespace css::uno;
namespace sc_apitest
{
#define NUMBER_OF_TESTS 31
#define NUMBER_OF_TESTS 32
class ScTableSheetObj : public CalcUnoApiTest, public apitest::XCellSeries,
public apitest::XDataPilotTablesSupplier,
public apitest::XMultipleOperation,
public apitest::XPrintAreas,
public apitest::XReplaceable,
......@@ -77,6 +79,9 @@ public:
CPPUNIT_TEST(testFillAuto);
CPPUNIT_TEST(testFillSeries);
// XDataPilotTablesSupplier
CPPUNIT_TEST(testGetDataPilotTables);
// XSearchable
CPPUNIT_TEST(testFindAll);
CPPUNIT_TEST(testFindNext);
......
......@@ -60,6 +60,7 @@ $(eval $(call gb_Library_add_exception_objects,subsequenttest,\
test/source/sheet/xdatapilotfieldgrouping \
test/source/sheet/xdatapilottable \
test/source/sheet/xdatapilottable2 \
test/source/sheet/xdatapilottablessupplier \
test/source/sheet/xfunctiondescriptions \
test/source/sheet/xheaderfootercontent \
test/source/sheet/xlabelrange \
......
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
/*
* 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 <test/sheet/xdatapilottablessupplier.hxx>
#include <com/sun/star/sheet/XDataPilotTables.hpp>
#include <com/sun/star/sheet/XDataPilotTablesSupplier.hpp>
#include <com/sun/star/uno/Reference.hxx>
#include <cppunit/extensions/HelperMacros.h>
using namespace css;
using namespace css::uno;
namespace apitest
{
void XDataPilotTablesSupplier::testGetDataPilotTables()
{
uno::Reference<sheet::XDataPilotTablesSupplier> xDPTS(init(), UNO_QUERY_THROW);
uno::Reference<sheet::XDataPilotTables> xDPT(xDPTS->getDataPilotTables(), UNO_QUERY_THROW);
CPPUNIT_ASSERT_MESSAGE("Unable to get XDataPilotTables", xDPT.is());
}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment