summaryrefslogtreecommitdiff
path: root/include/test/sheet
diff options
context:
space:
mode:
Diffstat (limited to 'include/test/sheet')
-rw-r--r--include/test/sheet/cellproperties.hxx32
-rw-r--r--include/test/sheet/datapilotfield.hxx34
-rw-r--r--include/test/sheet/tableautoformatfield.hxx30
-rw-r--r--include/test/sheet/xcellrangedata.hxx32
-rw-r--r--include/test/sheet/xcellrangereferrer.hxx36
-rw-r--r--include/test/sheet/xcellrangesquery.hxx40
-rw-r--r--include/test/sheet/xdatabaserange.hxx37
-rw-r--r--include/test/sheet/xdatapilotdescriptor.hxx50
-rw-r--r--include/test/sheet/xdatapilotfieldgrouping.hxx32
-rw-r--r--include/test/sheet/xdatapilottable.hxx36
-rw-r--r--include/test/sheet/xdatapilottable2.hxx55
-rw-r--r--include/test/sheet/xgoalseek.hxx31
-rw-r--r--include/test/sheet/xnamedrange.hxx58
-rw-r--r--include/test/sheet/xnamedranges.hxx65
-rw-r--r--include/test/sheet/xprintareas.hxx59
-rw-r--r--include/test/sheet/xsheetannotation.hxx60
-rw-r--r--include/test/sheet/xsheetannotations.hxx56
-rw-r--r--include/test/sheet/xsheetoutline.hxx57
-rw-r--r--include/test/sheet/xspreadsheetdocument.hxx35
-rw-r--r--include/test/sheet/xspreadsheets2.hxx84
20 files changed, 919 insertions, 0 deletions
diff --git a/include/test/sheet/cellproperties.hxx b/include/test/sheet/cellproperties.hxx
new file mode 100644
index 000000000000..49f9c37246cb
--- /dev/null
+++ b/include/test/sheet/cellproperties.hxx
@@ -0,0 +1,32 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/uno/XInterface.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST CellProperties
+{
+public:
+ virtual uno::Reference < uno::XInterface > init() = 0;
+
+ void testVertJustify();
+ void testRotateReference();
+
+protected:
+ ~CellProperties() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/datapilotfield.hxx b/include/test/sheet/datapilotfield.hxx
new file mode 100644
index 000000000000..253bdf474ac2
--- /dev/null
+++ b/include/test/sheet/datapilotfield.hxx
@@ -0,0 +1,34 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST DataPilotField
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ void testSortInfo();
+ void testLayoutInfo();
+ void testAutoShowInfo();
+ void testReference();
+ void testIsGroupField();
+
+protected:
+ ~DataPilotField() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/tableautoformatfield.hxx b/include/test/sheet/tableautoformatfield.hxx
new file mode 100644
index 000000000000..6b6d79f1fe57
--- /dev/null
+++ b/include/test/sheet/tableautoformatfield.hxx
@@ -0,0 +1,30 @@
+/* -*- 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 <com/sun/star/beans/XPropertySet.hpp>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class TableAutoFormatField
+{
+public:
+ //don't use virtual init() here
+ uno::Reference< beans::XPropertySet > initTest();
+
+ virtual uno::Reference< > getServiceFactory() = 0;
+
+ void testRotateReference();
+ void testVertJustify();
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xcellrangedata.hxx b/include/test/sheet/xcellrangedata.hxx
new file mode 100644
index 000000000000..dd56045b8649
--- /dev/null
+++ b/include/test/sheet/xcellrangedata.hxx
@@ -0,0 +1,32 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XCellRangeData
+{
+public:
+
+ virtual uno::Reference< uno::XInterface > getXCellRangeData() = 0;
+
+ void testGetDataArray();
+ void testSetDataArray();
+
+protected:
+ ~XCellRangeData() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xcellrangereferrer.hxx b/include/test/sheet/xcellrangereferrer.hxx
new file mode 100644
index 000000000000..22044302b087
--- /dev/null
+++ b/include/test/sheet/xcellrangereferrer.hxx
@@ -0,0 +1,36 @@
+/* -*- 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 <com/sun/star/table/CellRangeAddress.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XCellRangeReferrer
+{
+public:
+ XCellRangeReferrer( table::CellRangeAddress aCellRange ):
+ maCellRange( aCellRange ) {}
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ void testGetReferredCells();
+
+protected:
+ ~XCellRangeReferrer() {}
+
+private:
+ table::CellRangeAddress maCellRange;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xcellrangesquery.hxx b/include/test/sheet/xcellrangesquery.hxx
new file mode 100644
index 000000000000..3d419b7c8203
--- /dev/null
+++ b/include/test/sheet/xcellrangesquery.hxx
@@ -0,0 +1,40 @@
+/* -*- 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 <com/sun/star/uno/XInterface.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+
+namespace apitest {
+
+
+class OOO_DLLPUBLIC_TEST XCellRangesQuery
+{
+public:
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ //Testcases
+ void testQueryColumnDifference();
+ void testQueryContentDifference();
+ void testQueryEmptyCells();
+ void testQueryFormulaCells();
+ void testQueryIntersection();
+ void testQueryRowDifference();
+ void testQueryVisibleCells();
+
+protected:
+ ~XCellRangesQuery() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xdatabaserange.hxx b/include/test/sheet/xdatabaserange.hxx
new file mode 100644
index 000000000000..2be7e4dc663f
--- /dev/null
+++ b/include/test/sheet/xdatabaserange.hxx
@@ -0,0 +1,37 @@
+/* -*- 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 <rtl/ustring.hxx>
+#include <com/sun/star/uno/XInterface.hpp>
+#include <com/sun/star/uno/Reference.hxx>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XDatabaseRange
+{
+public:
+ virtual uno::Reference< uno::XInterface > init(const OUString& rDBName) = 0;
+
+ void testDataArea();
+ void testGetSortDescriptor();
+ void testGetSubtotalDescriptor();
+ void testGetImportDescriptor();
+ void testGetFilterDescriptor();
+ void testRefresh();
+
+protected:
+ ~XDatabaseRange() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xdatapilotdescriptor.hxx b/include/test/sheet/xdatapilotdescriptor.hxx
new file mode 100644
index 000000000000..55b26a3bbfe7
--- /dev/null
+++ b/include/test/sheet/xdatapilotdescriptor.hxx
@@ -0,0 +1,50 @@
+/* -*- 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 <com/sun/star/uno/XInterface.hpp>
+#include <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/sheet/XDataPilotDescriptor.hpp>
+
+#include <test/testdllapi.hxx>
+
+#include <vector>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XDataPilotDescriptor
+{
+public:
+ void testSourceRange();
+ void testTag();
+ void testGetFilterDescriptor();
+ void testGetDataPilotFields();
+ void testGetColumnFields();
+ void testGetRowFields();
+ void testGetPageFields();
+ void testGetDataFields();
+ void testGetHiddenFields();
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+protected:
+ ~XDataPilotDescriptor() {}
+
+private:
+
+ void testGetDataPilotFields_Impl( uno::Reference< sheet::XDataPilotDescriptor > xDescr );
+
+ void checkName( uno::Reference< container::XIndexAccess > xIndex, sal_Int32 nIndex );
+ static std::vector<OUString> maFieldNames;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xdatapilotfieldgrouping.hxx b/include/test/sheet/xdatapilotfieldgrouping.hxx
new file mode 100644
index 000000000000..fd11a45cb051
--- /dev/null
+++ b/include/test/sheet/xdatapilotfieldgrouping.hxx
@@ -0,0 +1,32 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/uno/XInterface.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XDataPilotFieldGrouping
+{
+public:
+ void testCreateNameGroup();
+ void testCreateDateGroup();
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+protected:
+ ~XDataPilotFieldGrouping() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xdatapilottable.hxx b/include/test/sheet/xdatapilottable.hxx
new file mode 100644
index 000000000000..27c5f2a7ca8c
--- /dev/null
+++ b/include/test/sheet/xdatapilottable.hxx
@@ -0,0 +1,36 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/table/XCell.hpp>
+#include <test/testdllapi.hxx>
+
+#include "cppunit/extensions/HelperMacros.h"
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XDataPilotTable
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+ virtual ~XDataPilotTable();
+
+ void testGetOutputRange();
+ void testRefresh();
+
+protected:
+ uno::Reference< table::XCell > xCellForChange;
+ uno::Reference< table::XCell > xCellForCheck;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xdatapilottable2.hxx b/include/test/sheet/xdatapilottable2.hxx
new file mode 100644
index 000000000000..b1dc31159af3
--- /dev/null
+++ b/include/test/sheet/xdatapilottable2.hxx
@@ -0,0 +1,55 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/table/CellRangeAddress.hpp>
+#include <com/sun/star/table/CellAddress.hpp>
+#include <com/sun/star/sheet/XDataPilotTable2.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <com/sun/star/uno/Sequence.h>
+
+#include "test/testdllapi.hxx"
+
+#include <vector>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XDataPilotTable2
+{
+public:
+ void testGetPositionData();
+ void testGetDrillDownData();
+ void testGetOutputRangeByType();
+ void testInsertDrillDownSheet();
+ virtual ~XDataPilotTable2();
+
+ virtual uno::Reference< uno::XInterface > initDP2() = 0;
+ virtual uno::Reference< uno::XInterface > getSheets() = 0;
+
+protected:
+
+private:
+ bool checkDrillDownSheetContent(uno::Reference< sheet::XSpreadsheet >, uno::Sequence< uno::Sequence < uno::Any > > aData);
+
+ void getOutputRanges(uno::Reference< sheet::XDataPilotTable2 >);
+ void buildDataFields(uno::Reference< sheet::XDataPilotTable2 >);
+ void buildResultCells(uno::Reference< sheet::XDataPilotTable2 >);
+
+ std::vector< table::CellAddress > maResultCells;
+ std::vector< sal_Int32 > maDataFieldDims;
+ table::CellRangeAddress maRangeWhole;
+ table::CellRangeAddress maRangeTable;
+ table::CellRangeAddress maRangeResult;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xgoalseek.hxx b/include/test/sheet/xgoalseek.hxx
new file mode 100644
index 000000000000..71fce12a356b
--- /dev/null
+++ b/include/test/sheet/xgoalseek.hxx
@@ -0,0 +1,31 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XGoalSeek
+{
+public:
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ void testSeekGoal();
+
+protected:
+ virtual ~XGoalSeek() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xnamedrange.hxx b/include/test/sheet/xnamedrange.hxx
new file mode 100644
index 000000000000..97a6afdf4926
--- /dev/null
+++ b/include/test/sheet/xnamedrange.hxx
@@ -0,0 +1,58 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2011 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include <rtl/ustring.hxx>
+#include <com/sun/star/sheet/XNamedRange.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XNamedRange
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ // XNamedRange
+ void testGetContent();
+ void testSetContent();
+ void testGetType();
+ void testSetType();
+ void testGetReferencePosition();
+ void testSetReferencePosition();
+protected:
+ ~XNamedRange() {}
+
+ virtual uno::Reference< sheet::XNamedRange> getNamedRange(const OUString&) = 0;
+
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xnamedranges.hxx b/include/test/sheet/xnamedranges.hxx
new file mode 100644
index 000000000000..d0d2eeedb66f
--- /dev/null
+++ b/include/test/sheet/xnamedranges.hxx
@@ -0,0 +1,65 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2011 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include <rtl/ustring.hxx>
+#include <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XNamedRanges
+{
+public:
+ // remove default entry
+ XNamedRanges();
+ // removes given entry
+ XNamedRanges(const OUString& rNameToRemove);
+
+ virtual ~XNamedRanges();
+
+ virtual uno::Reference< uno::XInterface > init(sal_Int32 nSheets = 0) = 0;
+
+ // XNamedRanges
+ void testAddNewByName();
+ void testAddNewFromTitles();
+ void testRemoveByName();
+ void testOutputList();
+
+protected:
+ uno::Reference< sheet::XSpreadsheet > xSheet;
+
+private:
+ OUString maNameToRemove;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xprintareas.hxx b/include/test/sheet/xprintareas.hxx
new file mode 100644
index 000000000000..08f534877690
--- /dev/null
+++ b/include/test/sheet/xprintareas.hxx
@@ -0,0 +1,59 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2012 Artur Dorda <artur.dorda+libo@gmail.com> (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+ #include <com/sun/star/sheet/XPrintAreas.hpp>
+ #include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XPrintAreas
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ void testSetAndGetPrintTitleColumns(); //getter and setter in one test case
+ void testSetAndGetPrintTitleRows();
+
+ void testGetPrintAreas(); // returns a sequence containing all print areas of the sheet.
+ void testSetPrintAreas(); // sets the print areas of the sheet.
+ void testGetTitleColumns(); // returns the range that is specified as title columns range.
+ void testSetTitleColumns(); // specifies a range of columns as title columns range.
+ void testGetTitleRows(); // returns the range that is specified as title rows range.
+ void testSetTitleRows(); // specifies a range of rows as title rows range.
+
+protected:
+ ~XPrintAreas() {}
+
+
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xsheetannotation.hxx b/include/test/sheet/xsheetannotation.hxx
new file mode 100644
index 000000000000..9dd552d2803d
--- /dev/null
+++ b/include/test/sheet/xsheetannotation.hxx
@@ -0,0 +1,60 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2013 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include <rtl/ustring.hxx>
+#include <com/sun/star/sheet/XSheetAnnotation.hpp>
+#include <test/testdllapi.hxx>
+
+#include <com/sun/star/table/CellAddress.hpp>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XSheetAnnotation
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ // XSheetAnnotation
+ void testGetPosition();
+ void testGetAuthor();
+ void testGetDate();
+ void testGetIsVisible();
+ void testSetIsVisible();
+
+protected:
+ ~XSheetAnnotation() {}
+
+ virtual uno::Reference< sheet::XSheetAnnotation> getAnnotation(table::CellAddress&) = 0;
+
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xsheetannotations.hxx b/include/test/sheet/xsheetannotations.hxx
new file mode 100644
index 000000000000..9c1c2111008c
--- /dev/null
+++ b/include/test/sheet/xsheetannotations.hxx
@@ -0,0 +1,56 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2013 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include <rtl/ustring.hxx>
+#include <com/sun/star/sheet/XSheetAnnotations.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XSheetAnnotations
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ // XSheetAnnotations
+ void testInsertNew();
+ void testRemoveByIndex();
+
+
+protected:
+ ~XSheetAnnotations() {}
+
+ virtual uno::Reference< sheet::XSheetAnnotations> getAnnotations() = 0;
+
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xsheetoutline.hxx b/include/test/sheet/xsheetoutline.hxx
new file mode 100644
index 000000000000..b52ac0eeb7aa
--- /dev/null
+++ b/include/test/sheet/xsheetoutline.hxx
@@ -0,0 +1,57 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2013 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include <rtl/ustring.hxx>
+#include <com/sun/star/sheet/XSheetOutline.hpp>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XSheetOutline
+{
+public:
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ // XSheetOutline
+ void testHideDetail();
+ void testShowDetail();
+ void testShowLevel();
+ void testUngroup();
+ void testGroup();
+ void testAutoOutline();
+ void testClearOutline();
+
+protected:
+ ~XSheetOutline() {}
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xspreadsheetdocument.hxx b/include/test/sheet/xspreadsheetdocument.hxx
new file mode 100644
index 000000000000..edeef9c4891c
--- /dev/null
+++ b/include/test/sheet/xspreadsheetdocument.hxx
@@ -0,0 +1,35 @@
+/* -*- 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 <com/sun/star/uno/Reference.hxx>
+#include <test/testdllapi.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class XSpreadsheetDocument
+{
+public:
+ XSpreadsheetDocument(sal_Int32 nSheets) : mnSheets(nSheets) {}
+
+ virtual uno::Reference< uno::XInterface > init() = 0;
+
+ void testGetSheets();
+
+protected:
+ ~XSpreadsheetDocument() {}
+
+private:
+ sal_Int32 mnSheets;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/test/sheet/xspreadsheets2.hxx b/include/test/sheet/xspreadsheets2.hxx
new file mode 100644
index 000000000000..83b9eddd15e7
--- /dev/null
+++ b/include/test/sheet/xspreadsheets2.hxx
@@ -0,0 +1,84 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Version: MPL 1.1 / GPLv3+ / LGPLv3+
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License or as specified alternatively below. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2011 Laurent Godard lgodard.libre@laposte.net (initial developer)
+ *
+ * All Rights Reserved.
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+ * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+ * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+ * instead of those above.
+ */
+
+#include "test/testdllapi.hxx"
+
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <com/sun/star/sheet/XNamedRanges.hpp>
+#include <com/sun/star/lang/XComponent.hpp>
+
+#include <rtl/ustring.hxx>
+
+using namespace com::sun::star;
+
+namespace apitest {
+
+class OOO_DLLPUBLIC_TEST XSpreadsheets2
+{
+public:
+ XSpreadsheets2();
+ virtual ~XSpreadsheets2();
+
+ // XSpreadsheets2
+ void testImportedSheetNameAndIndex();
+ void testImportString();
+ void testImportValue();
+ void testImportFormulaBasicMath();
+ void testImportFormulaWithNamedRange();
+ void testImportOverExistingNamedRange();
+ void testImportNamedRangeDefinedInSource();
+ void testImportNamedRangeRedefinedInSource();
+ void testImportNewNamedRange();
+ void testImportCellStyle();
+
+ virtual uno::Reference< lang::XComponent > getComponent() = 0;
+ virtual uno::Reference< uno::XInterface > init() = 0;
+ virtual uno::Reference< lang::XComponent > loadFromDesktop(const OUString&) = 0;
+ virtual void createFileURL(const OUString&, OUString&) = 0;
+
+protected:
+ uno::Reference< sheet::XSpreadsheetDocument> xDocument;
+
+private:
+ uno::Reference< sheet::XSpreadsheetDocument> getDoc(const OUString&, uno::Reference< lang::XComponent >&);
+ uno::Reference< sheet::XNamedRanges> getNamedRanges(uno::Reference< sheet::XSpreadsheetDocument >);
+ void importSheetToCopy();
+ bool isExternalReference(const OUString& aDestContent, const OUString& aSrcContent );
+
+ uno::Reference< sheet::XSpreadsheetDocument> xDestDoc;
+ uno::Reference< sheet::XSpreadsheet > xDestSheet;
+ uno::Reference< sheet::XSpreadsheet > xSrcSheet;
+ OUString aSrcSheetName;
+ OUString aSrcFileName;
+ OUString aDestFileBase;
+};
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */