[Libreoffice-commits] .: 2 commits - Repository.mk sc/CppunitTest_sc_cellrangeobj.mk sc/CppunitTest_sc_cellrangesbase.mk sc/CppunitTest_sc_databaserangeobj.mk sc/CppunitTest_sc_datapilotdescriptorbase.mk sc/CppunitTest_sc_datapilotfieldobj.mk sc/CppunitTest_sc_datapilottableobj.mk sc/CppunitTest_sc_namedrangeobj.mk sc/CppunitTest_sc_namedrangesobj.mk sc/CppunitTest_sc_spreadsheetobj.mk sc/CppunitTest_sc_tableautoformatfield.mk sc/CppunitTest_sc_tablesheetsobj.mk sc/Module_sc.mk sc/qa test/inc test/Library_subsequenttest.mk test/Library_test.mk test/Module_test.mk test/Package_inc.mk test/source

Markus Mohrhard mmohrhard at kemper.freedesktop.org
Mon Jan 23 10:48:18 PST 2012


 Repository.mk                                   |    1 
 sc/CppunitTest_sc_cellrangeobj.mk               |  142 +++++++
 sc/CppunitTest_sc_cellrangesbase.mk             |  142 -------
 sc/CppunitTest_sc_databaserangeobj.mk           |    3 
 sc/CppunitTest_sc_datapilotdescriptorbase.mk    |  142 -------
 sc/CppunitTest_sc_datapilotfieldobj.mk          |    4 
 sc/CppunitTest_sc_datapilottableobj.mk          |  142 +++++++
 sc/CppunitTest_sc_namedrangeobj.mk              |    4 
 sc/CppunitTest_sc_namedrangesobj.mk             |  142 +++++++
 sc/CppunitTest_sc_spreadsheetobj.mk             |  138 -------
 sc/CppunitTest_sc_tableautoformatfield.mk       |    1 
 sc/CppunitTest_sc_tablesheetsobj.mk             |  139 +++++++
 sc/Module_sc.mk                                 |   14 
 sc/qa/extras/cellproperties.cxx                 |  148 -------
 sc/qa/extras/datapilotfieldobj.cxx              |  264 --------------
 sc/qa/extras/sccellrangeobj.cxx                 |  116 ++++++
 sc/qa/extras/scdatabaserangeobj.cxx             |  106 +++++
 sc/qa/extras/scdatapilotfieldobj.cxx            |  123 ++++++
 sc/qa/extras/scdatapilottableobj.cxx            |  129 ++++++
 sc/qa/extras/scnamedrangeobj.cxx                |  117 ++++++
 sc/qa/extras/scnamedrangesobj.cxx               |  110 +++++
 sc/qa/extras/sctablesheetsobj.cxx               |  138 +++++++
 sc/qa/extras/tableautoformatfield.cxx           |  131 -------
 sc/qa/extras/testdocuments/rangenamessrc.ods    |binary
 sc/qa/extras/xcellrangesquery.cxx               |  196 ----------
 sc/qa/extras/xdatabaserange.cxx                 |  209 -----------
 sc/qa/extras/xdatapilotdescriptor.cxx           |  311 ----------------
 sc/qa/extras/xdatapilotfieldgrouping.cxx        |  149 --------
 sc/qa/extras/xdatapilottable.cxx                |  149 --------
 sc/qa/extras/xnamecontainer.cxx                 |   85 ----
 sc/qa/extras/xnamedrange.cxx                    |  201 ----------
 sc/qa/extras/xnamedranges.cxx                   |  259 -------------
 sc/qa/extras/xspreadsheets2.cxx                 |  447 ------------------------
 test/Library_subsequenttest.mk                  |   83 ++++
 test/Library_test.mk                            |    1 
 test/Module_test.mk                             |    1 
 test/Package_inc.mk                             |   11 
 test/inc/test/container/xnamecontainer.hxx      |   55 ++
 test/inc/test/sheet/cellproperties.hxx          |   48 ++
 test/inc/test/sheet/datapilotfield.hxx          |   50 ++
 test/inc/test/sheet/tableautoformatfield.hxx    |   49 ++
 test/inc/test/sheet/xcellrangesquery.hxx        |   57 +++
 test/inc/test/sheet/xdatabaserange.hxx          |   50 ++
 test/inc/test/sheet/xdatapilotdescriptor.hxx    |   67 +++
 test/inc/test/sheet/xdatapilotfieldgrouping.hxx |   48 ++
 test/inc/test/sheet/xdatapilottable.hxx         |   54 ++
 test/inc/test/sheet/xnamedrange.hxx             |   56 +++
 test/inc/test/sheet/xnamedranges.hxx            |   63 +++
 test/inc/test/sheet/xspreadsheets2.hxx          |   83 ++++
 test/inc/test/unoapi_test.hxx                   |   12 
 test/source/container/xnamecontainer.cxx        |   72 +++
 test/source/sheet/cellproperties.cxx            |   79 ++++
 test/source/sheet/datapilotfield.cxx            |  211 +++++++++++
 test/source/sheet/tableautoformatfield.cxx      |   87 ++++
 test/source/sheet/xcellrangesquery.cxx          |  116 ++++++
 test/source/sheet/xdatabaserange.cxx            |  145 +++++++
 test/source/sheet/xdatapilotdescriptor.cxx      |  222 +++++++++++
 test/source/sheet/xdatapilotfieldgrouping.cxx   |   62 +++
 test/source/sheet/xdatapilottable.cxx           |   75 ++++
 test/source/sheet/xnamedrange.cxx               |  152 ++++++++
 test/source/sheet/xnamedranges.cxx              |  215 +++++++++++
 test/source/sheet/xspreadsheets2.cxx            |  352 ++++++++++++++++++
 test/source/unoapi_test.cxx                     |    8 
 63 files changed, 3994 insertions(+), 2992 deletions(-)

New commits:
commit 95780ec73990f96dc16fc677c895d00fa1360008
Author: Markus Mohrhard <markus.mohrhard at googlemail.com>
Date:   Sat Jan 21 12:02:46 2012 +0100

    refactor concept for c++ based subsequenttests

diff --git a/sc/CppunitTest_sc_cellrangeobj.mk b/sc/CppunitTest_sc_cellrangeobj.mk
new file mode 100644
index 0000000..c72a1c2
--- /dev/null
+++ b/sc/CppunitTest_sc_cellrangeobj.mk
@@ -0,0 +1,142 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+# 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.
+#
+# The Initial Developer of the Original Code is
+#       Markus Mohrhard <markus.mohrhard at googlemail.com>
+# Portions created by the Initial Developer are Copyright (C) 2011 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# 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.
+#*************************************************************************
+
+$(eval $(call gb_CppunitTest_CppunitTest,sc_cellrangesbase))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sc_cellrangesbase, \
+    sc/qa/extras/sccellrangeobj\
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,sc_cellrangesbase, \
+    avmedia \
+    basegfx \
+    comphelper \
+    cppu \
+    cppuhelper \
+    drawinglayer \
+    editeng \
+    fileacc \
+    for \
+    forui \
+    i18nisolang1 \
+    msfilter \
+    oox \
+    sal \
+    salhelper \
+    sax \
+    sb \
+    sc \
+    sfx \
+    sot \
+    svl \
+    svt \
+    svx \
+    svxcore \
+	test \
+    tl \
+    tk \
+    subsequenttest \
+    ucbhelper \
+	unotest \
+    utl \
+    vbahelper \
+    vcl \
+    xo \
+	$(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sc_cellrangesbase,\
+    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
+    -I$(realpath $(SRCDIR)/sc/inc) \
+    $$(INCLUDE) \
+    -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_CppunitTest_add_api,sc_cellrangesbase,\
+    offapi \
+    udkapi \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,sc_cellrangesbase))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,sc_cellrangesbase,\
+    types \
+))
+
+$(eval $(call gb_CppunitTest_add_components,sc_cellrangesbase,\
+    basic/util/sb \
+    comphelper/util/comphelp \
+    configmgr/source/configmgr \
+    dbaccess/util/dba \
+    fileaccess/source/fileacc \
+    filter/source/config/cache/filterconfig1 \
+    forms/util/frm \
+    framework/util/fwk \
+    i18npool/util/i18npool \
+    oox/util/oox \
+    package/source/xstor/xstor \
+    package/util/package2 \
+    sax/source/expatwrap/expwrap \
+    sax/source/fastparser/fastsax \
+    sc/util/sc \
+    sc/util/scd \
+    sc/util/scfilt \
+    sc/util/vbaobj \
+    scripting/source/basprov/basprov \
+    scripting/util/scriptframe \
+    sfx2/util/sfx \
+    sot/util/sot \
+    svl/source/fsstor/fsstorage \
+    toolkit/util/tk \
+    ucb/source/core/ucb1 \
+    ucb/source/ucp/file/ucpfile1 \
+    ucb/source/ucp/tdoc/ucptdoc1 \
+    unotools/util/utl \
+    unoxml/source/rdf/unordf \
+    unoxml/source/service/unoxml \
+))
+
+$(eval $(call gb_CppunitTest_set_args,sc_cellrangesbase,\
+    --headless \
+    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
+    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
+))
+    # .../spool is required for the (somewhat strange) filter configuration
+
+# we need to
+# a) explicitly depend on library msword because it is not implied by a link
+#    relation
+# b) explicitly depend on the sc resource files needed at unit-test runtime
+$(call gb_CppunitTest_get_target,sc_cellrangesbase) : \
+    $(WORKDIR)/AllLangRes/sc \
+    $(call gb_Library_get_target,localedata_en) \
+    $(call gb_Library_get_target,scfilt) \
+
+# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_cellrangesbase.mk b/sc/CppunitTest_sc_cellrangesbase.mk
deleted file mode 100644
index 12c96a8..0000000
--- a/sc/CppunitTest_sc_cellrangesbase.mk
+++ /dev/null
@@ -1,143 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#*************************************************************************
-# 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.
-#
-# The Initial Developer of the Original Code is
-#       Markus Mohrhard <markus.mohrhard at googlemail.com>
-# Portions created by the Initial Developer are Copyright (C) 2011 the
-# Initial Developer. All Rights Reserved.
-#
-# Major Contributor(s):
-#
-# 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.
-#*************************************************************************
-
-$(eval $(call gb_CppunitTest_CppunitTest,sc_cellrangesbase))
-
-$(eval $(call gb_CppunitTest_add_exception_objects,sc_cellrangesbase, \
-    sc/qa/extras/xcellrangesquery \
-    sc/qa/extras/cellproperties \
-))
-
-$(eval $(call gb_CppunitTest_add_linked_libs,sc_cellrangesbase, \
-    avmedia \
-    basegfx \
-    comphelper \
-    cppu \
-    cppuhelper \
-    drawinglayer \
-    editeng \
-    fileacc \
-    for \
-    forui \
-    i18nisolang1 \
-    msfilter \
-    oox \
-    sal \
-    salhelper \
-    sax \
-    sb \
-    sc \
-    sfx \
-    sot \
-    svl \
-    svt \
-    svx \
-    svxcore \
-	test \
-    tl \
-    tk \
-    subsequenttest \
-    ucbhelper \
-	unotest \
-    utl \
-    vbahelper \
-    vcl \
-    xo \
-	$(gb_STDLIBS) \
-))
-
-$(eval $(call gb_CppunitTest_set_include,sc_cellrangesbase,\
-    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
-    -I$(realpath $(SRCDIR)/sc/inc) \
-    $$(INCLUDE) \
-    -I$(OUTDIR)/inc \
-))
-
-$(eval $(call gb_CppunitTest_add_api,sc_cellrangesbase,\
-    offapi \
-    udkapi \
-))
-
-$(eval $(call gb_CppunitTest_uses_ure,sc_cellrangesbase))
-
-$(eval $(call gb_CppunitTest_add_type_rdbs,sc_cellrangesbase,\
-    types \
-))
-
-$(eval $(call gb_CppunitTest_add_components,sc_cellrangesbase,\
-    basic/util/sb \
-    comphelper/util/comphelp \
-    configmgr/source/configmgr \
-    dbaccess/util/dba \
-    fileaccess/source/fileacc \
-    filter/source/config/cache/filterconfig1 \
-    forms/util/frm \
-    framework/util/fwk \
-    i18npool/util/i18npool \
-    oox/util/oox \
-    package/source/xstor/xstor \
-    package/util/package2 \
-    sax/source/expatwrap/expwrap \
-    sax/source/fastparser/fastsax \
-    sc/util/sc \
-    sc/util/scd \
-    sc/util/scfilt \
-    sc/util/vbaobj \
-    scripting/source/basprov/basprov \
-    scripting/util/scriptframe \
-    sfx2/util/sfx \
-    sot/util/sot \
-    svl/source/fsstor/fsstorage \
-    toolkit/util/tk \
-    ucb/source/core/ucb1 \
-    ucb/source/ucp/file/ucpfile1 \
-    ucb/source/ucp/tdoc/ucptdoc1 \
-    unotools/util/utl \
-    unoxml/source/rdf/unordf \
-    unoxml/source/service/unoxml \
-))
-
-$(eval $(call gb_CppunitTest_set_args,sc_cellrangesbase,\
-    --headless \
-    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
-    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
-))
-    # .../spool is required for the (somewhat strange) filter configuration
-
-# we need to
-# a) explicitly depend on library msword because it is not implied by a link
-#    relation
-# b) explicitly depend on the sc resource files needed at unit-test runtime
-$(call gb_CppunitTest_get_target,sc_cellrangesbase) : \
-    $(WORKDIR)/AllLangRes/sc \
-    $(call gb_Library_get_target,localedata_en) \
-    $(call gb_Library_get_target,scfilt) \
-
-# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_databaserangeobj.mk b/sc/CppunitTest_sc_databaserangeobj.mk
index a5ba678..d201ca8 100644
--- a/sc/CppunitTest_sc_databaserangeobj.mk
+++ b/sc/CppunitTest_sc_databaserangeobj.mk
@@ -31,7 +31,7 @@
 $(eval $(call gb_CppunitTest_CppunitTest,sc_databaserangeobj))
 
 $(eval $(call gb_CppunitTest_add_exception_objects,sc_databaserangeobj, \
-    sc/qa/extras/xdatabaserange \
+    sc/qa/extras/scdatabaserangeobj \
 ))
 
 $(eval $(call gb_CppunitTest_add_linked_libs,sc_databaserangeobj, \
@@ -55,6 +55,7 @@ $(eval $(call gb_CppunitTest_add_linked_libs,sc_databaserangeobj, \
     sc \
     sfx \
     sot \
+    subsequenttest \
     svl \
     svt \
     svx \
diff --git a/sc/CppunitTest_sc_datapilotdescriptorbase.mk b/sc/CppunitTest_sc_datapilotdescriptorbase.mk
deleted file mode 100644
index 31a49b8..0000000
--- a/sc/CppunitTest_sc_datapilotdescriptorbase.mk
+++ /dev/null
@@ -1,143 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#*************************************************************************
-# 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.
-#
-# The Initial Developer of the Original Code is
-#       Markus Mohrhard <markus.mohrhard at googlemail.com>
-# Portions created by the Initial Developer are Copyright (C) 2011 the
-# Initial Developer. All Rights Reserved.
-#
-# Major Contributor(s):
-#
-# 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.
-#*************************************************************************
-
-$(eval $(call gb_CppunitTest_CppunitTest,sc_datapilotdescriptorbase))
-
-$(eval $(call gb_CppunitTest_add_exception_objects,sc_datapilotdescriptorbase, \
-    sc/qa/extras/xdatapilotdescriptor \
-    sc/qa/extras/xdatapilottable \
-))
-
-$(eval $(call gb_CppunitTest_add_linked_libs,sc_datapilotdescriptorbase, \
-    avmedia \
-    basegfx \
-    comphelper \
-    cppu \
-    cppuhelper \
-    drawinglayer \
-    editeng \
-    fileacc \
-    for \
-    forui \
-    i18nisolang1 \
-    msfilter \
-    oox \
-    sal \
-    salhelper \
-    sax \
-    sb \
-    sc \
-    sfx \
-    sot \
-    svl \
-    svt \
-    svx \
-    svxcore \
-	test \
-    tl \
-    tk \
-    subsequenttest \
-    ucbhelper \
-	unotest \
-    utl \
-    vbahelper \
-    vcl \
-    xo \
-	$(gb_STDLIBS) \
-))
-
-$(eval $(call gb_CppunitTest_set_include,sc_datapilotdescriptorbase,\
-    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
-    -I$(realpath $(SRCDIR)/sc/inc) \
-    $$(INCLUDE) \
-    -I$(OUTDIR)/inc \
-))
-
-$(eval $(call gb_CppunitTest_add_api,sc_datapilotdescriptorbase,\
-    offapi \
-    udkapi \
-))
-
-$(eval $(call gb_CppunitTest_uses_ure,sc_datapilotdescriptorbase))
-
-$(eval $(call gb_CppunitTest_add_type_rdbs,sc_datapilotdescriptorbase,\
-    types \
-))
-
-$(eval $(call gb_CppunitTest_add_components,sc_datapilotdescriptorbase,\
-    basic/util/sb \
-    comphelper/util/comphelp \
-    configmgr/source/configmgr \
-    dbaccess/util/dba \
-    fileaccess/source/fileacc \
-    filter/source/config/cache/filterconfig1 \
-    forms/util/frm \
-    framework/util/fwk \
-    i18npool/util/i18npool \
-    oox/util/oox \
-    package/source/xstor/xstor \
-    package/util/package2 \
-    sax/source/expatwrap/expwrap \
-    sax/source/fastparser/fastsax \
-    sc/util/sc \
-    sc/util/scd \
-    sc/util/scfilt \
-    sc/util/vbaobj \
-    scripting/source/basprov/basprov \
-    scripting/util/scriptframe \
-    sfx2/util/sfx \
-    sot/util/sot \
-    svl/source/fsstor/fsstorage \
-    toolkit/util/tk \
-    ucb/source/core/ucb1 \
-    ucb/source/ucp/file/ucpfile1 \
-    ucb/source/ucp/tdoc/ucptdoc1 \
-    unotools/util/utl \
-    unoxml/source/rdf/unordf \
-    unoxml/source/service/unoxml \
-))
-
-$(eval $(call gb_CppunitTest_set_args,sc_datapilotdescriptorbase,\
-    --headless \
-    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
-    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
-))
-    # .../spool is required for the (somewhat strange) filter configuration
-
-# we need to
-# a) explicitly depend on library msword because it is not implied by a link
-#    relation
-# b) explicitly depend on the sc resource files needed at unit-test runtime
-$(call gb_CppunitTest_get_target,sc_datapilotdescriptorbase) : \
-    $(WORKDIR)/AllLangRes/sc \
-    $(call gb_Library_get_target,localedata_en) \
-    $(call gb_Library_get_target,scfilt) \
-
-# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_datapilotfieldobj.mk b/sc/CppunitTest_sc_datapilotfieldobj.mk
index 5898d3d..01f8c41 100644
--- a/sc/CppunitTest_sc_datapilotfieldobj.mk
+++ b/sc/CppunitTest_sc_datapilotfieldobj.mk
@@ -31,8 +31,7 @@
 $(eval $(call gb_CppunitTest_CppunitTest,sc_datapilotfieldobj))
 
 $(eval $(call gb_CppunitTest_add_exception_objects,sc_datapilotfieldobj, \
-    sc/qa/extras/datapilotfieldobj \
-    sc/qa/extras/xdatapilotfieldgrouping \
+    sc/qa/extras/scdatapilotfieldobj \
 ))
 
 $(eval $(call gb_CppunitTest_add_linked_libs,sc_datapilotfieldobj, \
diff --git a/sc/CppunitTest_sc_datapilottableobj.mk b/sc/CppunitTest_sc_datapilottableobj.mk
new file mode 100644
index 0000000..05bca55
--- /dev/null
+++ b/sc/CppunitTest_sc_datapilottableobj.mk
@@ -0,0 +1,142 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+# 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.
+#
+# The Initial Developer of the Original Code is
+#       Markus Mohrhard <markus.mohrhard at googlemail.com>
+# Portions created by the Initial Developer are Copyright (C) 2011 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# 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.
+#*************************************************************************
+
+$(eval $(call gb_CppunitTest_CppunitTest,sc_datapilottableobj))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sc_datapilottableobj, \
+    sc/qa/extras/scdatapilottableobj \
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,sc_datapilottableobj, \
+    avmedia \
+    basegfx \
+    comphelper \
+    cppu \
+    cppuhelper \
+    drawinglayer \
+    editeng \
+    fileacc \
+    for \
+    forui \
+    i18nisolang1 \
+    msfilter \
+    oox \
+    sal \
+    salhelper \
+    sax \
+    sb \
+    sc \
+    sfx \
+    sot \
+    svl \
+    svt \
+    svx \
+    svxcore \
+	test \
+    tl \
+    tk \
+    subsequenttest \
+    ucbhelper \
+	unotest \
+    utl \
+    vbahelper \
+    vcl \
+    xo \
+	$(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sc_datapilottableobj,\
+    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
+    -I$(realpath $(SRCDIR)/sc/inc) \
+    $$(INCLUDE) \
+    -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_CppunitTest_add_api,sc_datapilottableobj,\
+    offapi \
+    udkapi \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,sc_datapilottableobj))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,sc_datapilottableobj,\
+    types \
+))
+
+$(eval $(call gb_CppunitTest_add_components,sc_datapilottableobj,\
+    basic/util/sb \
+    comphelper/util/comphelp \
+    configmgr/source/configmgr \
+    dbaccess/util/dba \
+    fileaccess/source/fileacc \
+    filter/source/config/cache/filterconfig1 \
+    forms/util/frm \
+    framework/util/fwk \
+    i18npool/util/i18npool \
+    oox/util/oox \
+    package/source/xstor/xstor \
+    package/util/package2 \
+    sax/source/expatwrap/expwrap \
+    sax/source/fastparser/fastsax \
+    sc/util/sc \
+    sc/util/scd \
+    sc/util/scfilt \
+    sc/util/vbaobj \
+    scripting/source/basprov/basprov \
+    scripting/util/scriptframe \
+    sfx2/util/sfx \
+    sot/util/sot \
+    svl/source/fsstor/fsstorage \
+    toolkit/util/tk \
+    ucb/source/core/ucb1 \
+    ucb/source/ucp/file/ucpfile1 \
+    ucb/source/ucp/tdoc/ucptdoc1 \
+    unotools/util/utl \
+    unoxml/source/rdf/unordf \
+    unoxml/source/service/unoxml \
+))
+
+$(eval $(call gb_CppunitTest_set_args,sc_datapilottableobj,\
+    --headless \
+    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
+    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
+))
+    # .../spool is required for the (somewhat strange) filter configuration
+
+# we need to
+# a) explicitly depend on library msword because it is not implied by a link
+#    relation
+# b) explicitly depend on the sc resource files needed at unit-test runtime
+$(call gb_CppunitTest_get_target,sc_datapilottableobj) : \
+    $(WORKDIR)/AllLangRes/sc \
+    $(call gb_Library_get_target,localedata_en) \
+    $(call gb_Library_get_target,scfilt) \
+
+# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_namedrangeobj.mk b/sc/CppunitTest_sc_namedrangeobj.mk
index bd2d7d9..948e84d 100644
--- a/sc/CppunitTest_sc_namedrangeobj.mk
+++ b/sc/CppunitTest_sc_namedrangeobj.mk
@@ -31,8 +31,7 @@
 $(eval $(call gb_CppunitTest_CppunitTest,sc_namedrangeobj))
 
 $(eval $(call gb_CppunitTest_add_exception_objects,sc_namedrangeobj, \
-    sc/qa/extras/xnamedranges \
-    sc/qa/extras/xnamedrange \
+    sc/qa/extras/scnamedrangeobj \
 ))
 
 $(eval $(call gb_CppunitTest_add_linked_libs,sc_namedrangeobj, \
diff --git a/sc/CppunitTest_sc_namedrangesobj.mk b/sc/CppunitTest_sc_namedrangesobj.mk
new file mode 100644
index 0000000..6a4e968
--- /dev/null
+++ b/sc/CppunitTest_sc_namedrangesobj.mk
@@ -0,0 +1,142 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+# 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.
+#
+# The Initial Developer of the Original Code is
+#       Markus Mohrhard <markus.mohrhard at googlemail.com>
+# Portions created by the Initial Developer are Copyright (C) 2011 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# 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.
+#*************************************************************************
+
+$(eval $(call gb_CppunitTest_CppunitTest,sc_namedrangesobj))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sc_namedrangesobj, \
+    sc/qa/extras/scnamedrangesobj \
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,sc_namedrangesobj, \
+    avmedia \
+    basegfx \
+    comphelper \
+    cppu \
+    cppuhelper \
+    drawinglayer \
+    editeng \
+    fileacc \
+    for \
+    forui \
+    i18nisolang1 \
+    msfilter \
+    oox \
+    sal \
+    salhelper \
+    sax \
+    sb \
+    sc \
+    sfx \
+    sot \
+    svl \
+    svt \
+    svx \
+    svxcore \
+	test \
+    tl \
+    tk \
+    subsequenttest \
+    ucbhelper \
+	unotest \
+    utl \
+    vbahelper \
+    vcl \
+    xo \
+	$(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sc_namedrangesobj,\
+    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
+    -I$(realpath $(SRCDIR)/sc/inc) \
+    $$(INCLUDE) \
+    -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_CppunitTest_add_api,sc_namedrangesobj,\
+    offapi \
+    udkapi \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,sc_namedrangesobj))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,sc_namedrangesobj,\
+    types \
+))
+
+$(eval $(call gb_CppunitTest_add_components,sc_namedrangesobj,\
+    basic/util/sb \
+    comphelper/util/comphelp \
+    configmgr/source/configmgr \
+    dbaccess/util/dba \
+    fileaccess/source/fileacc \
+    filter/source/config/cache/filterconfig1 \
+    forms/util/frm \
+    framework/util/fwk \
+    i18npool/util/i18npool \
+    oox/util/oox \
+    package/source/xstor/xstor \
+    package/util/package2 \
+    sax/source/expatwrap/expwrap \
+    sax/source/fastparser/fastsax \
+    sc/util/sc \
+    sc/util/scd \
+    sc/util/scfilt \
+    sc/util/vbaobj \
+    scripting/source/basprov/basprov \
+    scripting/util/scriptframe \
+    sfx2/util/sfx \
+    sot/util/sot \
+    svl/source/fsstor/fsstorage \
+    toolkit/util/tk \
+    ucb/source/core/ucb1 \
+    ucb/source/ucp/file/ucpfile1 \
+    ucb/source/ucp/tdoc/ucptdoc1 \
+    unotools/util/utl \
+    unoxml/source/rdf/unordf \
+    unoxml/source/service/unoxml \
+))
+
+$(eval $(call gb_CppunitTest_set_args,sc_namedrangesobj,\
+    --headless \
+    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
+    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
+))
+    # .../spool is required for the (somewhat strange) filter configuration
+
+# we need to
+# a) explicitly depend on library msword because it is not implied by a link
+#    relation
+# b) explicitly depend on the sc resource files needed at unit-test runtime
+$(call gb_CppunitTest_get_target,sc_namedrangesobj) : \
+    $(WORKDIR)/AllLangRes/sc \
+    $(call gb_Library_get_target,localedata_en) \
+    $(call gb_Library_get_target,scfilt) \
+
+# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_spreadsheetobj.mk b/sc/CppunitTest_sc_spreadsheetobj.mk
deleted file mode 100644
index 29779bd..0000000
--- a/sc/CppunitTest_sc_spreadsheetobj.mk
+++ /dev/null
@@ -1,139 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#*************************************************************************
-# 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.
-#
-# The Initial Developer of the Original Code is
-#       Markus Mohrhard <markus.mohrhard at googlemail.com>
-# Portions created by the Initial Developer are Copyright (C) 2011 the
-# Initial Developer. All Rights Reserved.
-#
-# Major Contributor(s):
-#
-# 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.
-#*************************************************************************
-
-$(eval $(call gb_CppunitTest_CppunitTest,sc_spreadsheetobj))
-
-$(eval $(call gb_CppunitTest_add_exception_objects,sc_spreadsheetobj, \
-    sc/qa/extras/xspreadsheets2 \
-))
-
-$(eval $(call gb_CppunitTest_add_linked_libs,sc_spreadsheetobj, \
-    avmedia \
-    basegfx \
-    comphelper \
-    cppu \
-    cppuhelper \
-    drawinglayer \
-    editeng \
-    fileacc \
-    for \
-    forui \
-    i18nisolang1 \
-    msfilter \
-    oox \
-    sal \
-    salhelper \
-    sax \
-    sb \
-    sc \
-    sfx \
-    sot \
-    subsequenttest \
-    svl \
-    svt \
-    svx \
-    svxcore \
-	test \
-    tl \
-    tk \
-    ucbhelper \
-	unotest \
-    utl \
-    vbahelper \
-    vcl \
-    xo \
-	$(gb_STDLIBS) \
-))
-
-$(eval $(call gb_CppunitTest_set_include,sc_spreadsheetobj,\
-    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
-    -I$(realpath $(SRCDIR)/sc/inc) \
-    $$(INCLUDE) \
-    -I$(OUTDIR)/inc \
-))
-
-$(eval $(call gb_CppunitTest_add_api,sc_spreadsheetobj,\
-    offapi \
-    udkapi \
-))
-
-$(eval $(call gb_CppunitTest_uses_ure,sc_spreadsheetobj))
-
-$(eval $(call gb_CppunitTest_add_type_rdbs,sc_spreadsheetobj,\
-    types \
-))
-
-$(eval $(call gb_CppunitTest_add_components,sc_spreadsheetobj,\
-    basic/util/sb \
-    comphelper/util/comphelp \
-    configmgr/source/configmgr \
-    dbaccess/util/dba \
-    fileaccess/source/fileacc \
-    filter/source/config/cache/filterconfig1 \
-    forms/util/frm \
-    framework/util/fwk \
-    i18npool/util/i18npool \
-    oox/util/oox \
-    package/source/xstor/xstor \
-    package/util/package2 \
-    sax/source/expatwrap/expwrap \
-    sax/source/fastparser/fastsax \
-    sc/util/sc \
-    sc/util/scd \
-    sc/util/scfilt \
-    sc/util/vbaobj \
-    scripting/source/basprov/basprov \
-    scripting/util/scriptframe \
-    sfx2/util/sfx \
-    sot/util/sot \
-    svl/source/fsstor/fsstorage \
-    toolkit/util/tk \
-    ucb/source/core/ucb1 \
-    ucb/source/ucp/file/ucpfile1 \
-    ucb/source/ucp/tdoc/ucptdoc1 \
-    unotools/util/utl \
-    unoxml/source/rdf/unordf \
-    unoxml/source/service/unoxml \
-))
-
-$(eval $(call gb_CppunitTest_set_args,sc_spreadsheetobj,\
-    --headless \
-    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
-    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
-))
-    # .../spool is required for the (somewhat strange) filter configuration
-
-# we need to
-# a) explicitly depend on library msword because it is not implied by a link
-#    relation
-# b) explicitly depend on the sc resource files needed at unit-test runtime
-$(call gb_CppunitTest_get_target,sc_spreadsheetobj) : $(call gb_Library_get_target,scfilt) $(WORKDIR)/AllLangRes/sc
-
-# vim: set noet sw=4 ts=4:
diff --git a/sc/CppunitTest_sc_tablesheetsobj.mk b/sc/CppunitTest_sc_tablesheetsobj.mk
new file mode 100644
index 0000000..c7f43d0
--- /dev/null
+++ b/sc/CppunitTest_sc_tablesheetsobj.mk
@@ -0,0 +1,139 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+# 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.
+#
+# The Initial Developer of the Original Code is
+#       Markus Mohrhard <markus.mohrhard at googlemail.com>
+# Portions created by the Initial Developer are Copyright (C) 2011 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# 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.
+#*************************************************************************
+
+$(eval $(call gb_CppunitTest_CppunitTest,sc_spreadsheetobj))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sc_spreadsheetobj, \
+    sc/qa/extras/sctablesheetsobj \
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,sc_spreadsheetobj, \
+    avmedia \
+    basegfx \
+    comphelper \
+    cppu \
+    cppuhelper \
+    drawinglayer \
+    editeng \
+    fileacc \
+    for \
+    forui \
+    i18nisolang1 \
+    msfilter \
+    oox \
+    sal \
+    salhelper \
+    sax \
+    sb \
+    sc \
+    sfx \
+    sot \
+    subsequenttest \
+    svl \
+    svt \
+    svx \
+    svxcore \
+	test \
+    tl \
+    tk \
+    ucbhelper \
+	unotest \
+    utl \
+    vbahelper \
+    vcl \
+    xo \
+	$(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sc_spreadsheetobj,\
+    -I$(realpath $(SRCDIR)/sc/source/ui/inc) \
+    -I$(realpath $(SRCDIR)/sc/inc) \
+    $$(INCLUDE) \
+    -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_CppunitTest_add_api,sc_spreadsheetobj,\
+    offapi \
+    udkapi \
+))
+
+$(eval $(call gb_CppunitTest_uses_ure,sc_spreadsheetobj))
+
+$(eval $(call gb_CppunitTest_add_type_rdbs,sc_spreadsheetobj,\
+    types \
+))
+
+$(eval $(call gb_CppunitTest_add_components,sc_spreadsheetobj,\
+    basic/util/sb \
+    comphelper/util/comphelp \
+    configmgr/source/configmgr \
+    dbaccess/util/dba \
+    fileaccess/source/fileacc \
+    filter/source/config/cache/filterconfig1 \
+    forms/util/frm \
+    framework/util/fwk \
+    i18npool/util/i18npool \
+    oox/util/oox \
+    package/source/xstor/xstor \
+    package/util/package2 \
+    sax/source/expatwrap/expwrap \
+    sax/source/fastparser/fastsax \
+    sc/util/sc \
+    sc/util/scd \
+    sc/util/scfilt \
+    sc/util/vbaobj \
+    scripting/source/basprov/basprov \
+    scripting/util/scriptframe \
+    sfx2/util/sfx \
+    sot/util/sot \
+    svl/source/fsstor/fsstorage \
+    toolkit/util/tk \
+    ucb/source/core/ucb1 \
+    ucb/source/ucp/file/ucpfile1 \
+    ucb/source/ucp/tdoc/ucptdoc1 \
+    unotools/util/utl \
+    unoxml/source/rdf/unordf \
+    unoxml/source/service/unoxml \
+))
+
+$(eval $(call gb_CppunitTest_set_args,sc_spreadsheetobj,\
+    --headless \
+    --protector unoexceptionprotector$(gb_Library_DLLEXT) unoexceptionprotector \
+    "-env:CONFIGURATION_LAYERS=xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry) module:$(call gb_CppunitTarget__make_url,$(OUTDIR)/xml/registry/spool) xcsxcu:$(call gb_CppunitTarget__make_url,$(OUTDIR)/unittest/registry)" \
+))
+    # .../spool is required for the (somewhat strange) filter configuration
+
+# we need to
+# a) explicitly depend on library msword because it is not implied by a link
+#    relation
+# b) explicitly depend on the sc resource files needed at unit-test runtime
+$(call gb_CppunitTest_get_target,sc_spreadsheetobj) : $(call gb_Library_get_target,scfilt) $(WORKDIR)/AllLangRes/sc
+
+# vim: set noet sw=4 ts=4:
diff --git a/sc/Module_sc.mk b/sc/Module_sc.mk
index 266f822..d7d28ef 100644
--- a/sc/Module_sc.mk
+++ b/sc/Module_sc.mk
@@ -35,21 +35,21 @@ $(eval $(call gb_Module_add_targets,sc,\
 ))
 
 $(eval $(call gb_Module_add_check_targets,sc,\
-    CppunitTest_sc_filters_test \
     CppunitTest_sc_ucalc \
+    CppunitTest_sc_filters_test \
 ))
 
 $(eval $(call gb_Module_add_subsequentcheck_targets,sc,\
-    CppunitTest_sc_cellrangesbase \
-    CppunitTest_sc_datapilotdescriptorbase \
+    JunitTest_sc_complex \
+    JunitTest_sc_unoapi \
+    CppunitTest_sc_cellrangeobj \
+    CppunitTest_sc_datapilottableobj \
     CppunitTest_sc_datapilotfieldobj \
     CppunitTest_sc_macros_test \
     CppunitTest_sc_namedrangeobj \
-    CppunitTest_sc_spreadsheetobj \
+    CppunitTest_sc_namedrangesobj \
+    CppunitTest_sc_tablesheetsobj \
     CppunitTest_sc_subsequent_filters_test \
-    CppunitTest_sc_tableautoformatfield \
-    JunitTest_sc_complex \
-    JunitTest_sc_unoapi \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/sc/qa/extras/cellproperties.cxx b/sc/qa/extras/cellproperties.cxx
deleted file mode 100644
index 2937915..0000000
--- a/sc/qa/extras/cellproperties.cxx
+++ /dev/null
@@ -1,148 +0,0 @@
-/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
-
-#include <com/sun/star/beans/XPropertySet.hpp>
-#include <com/sun/star/table/CellVertJustify.hpp>
-#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
-#include <com/sun/star/sheet/XSpreadsheet.hpp>
-#include <com/sun/star/table/XCellRange.hpp>
-#include <com/sun/star/util/XCloseable.hpp>
-
-namespace ScCellRangeBase {
-
-#define NUMBER_OF_TESTS 2
-
-class ScCellProperties : public UnoApiTest
-{
-public:
-    virtual void setUp();
-    virtual void tearDown();
-
-    void testVertJustify();
-    void testRotateReference();
-    CPPUNIT_TEST_SUITE(ScCellProperties);
-    CPPUNIT_TEST(testVertJustify);
-    CPPUNIT_TEST(testRotateReference);
-    CPPUNIT_TEST_SUITE_END();
-
-private:
-    uno::Reference < beans::XPropertySet > init();
-
-    static int nTest;
-    static uno::Reference< lang::XComponent > xComponent;
-};
-
-int ScCellProperties::nTest = 0;
-uno::Reference< lang::XComponent > ScCellProperties::xComponent;
-
-
-void ScCellProperties::testVertJustify()
-{
-    uno::Reference< beans::XPropertySet > xCellRangeBase = init();
-    rtl::OUString aVertJustify(RTL_CONSTASCII_USTRINGPARAM("VertJustify"));
-    uno::Any aOldVertJustify = xCellRangeBase->getPropertyValue(aVertJustify);
-    sal_Int32 aValue = 0;
-    CPPUNIT_ASSERT(aOldVertJustify >>= aValue);
-    std::cout << "Old VertJustify value: " << aValue << std::endl;
-
-    uno::Any aNewVertJustify;
-    aNewVertJustify <<= static_cast<sal_Int32>(3);
-    xCellRangeBase->setPropertyValue(aVertJustify, aNewVertJustify);
-    uno::Any aVertJustifyControllValue = xCellRangeBase->getPropertyValue(aVertJustify);
-    CPPUNIT_ASSERT(aVertJustifyControllValue >>= aValue);
-    std::cout << "New VertJustify value: " << aValue << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("value has not been changed", aValue == 3);
-}
-
-void ScCellProperties::testRotateReference()
-{
-    uno::Reference< beans::XPropertySet > xCellRangeBase = init();
-    rtl::OUString aRotateReference(RTL_CONSTASCII_USTRINGPARAM("RotateReference"));
-    uno::Any aOldRotateReference = xCellRangeBase->getPropertyValue(aRotateReference);
-    sal_Int32 aValue = 0;
-    CPPUNIT_ASSERT(aOldRotateReference >>= aValue);
-    std::cout << "Old RotateReference Value: " << aValue << std::endl;
-
-    uno::Any aNewRotateReference;
-    aNewRotateReference <<= static_cast<sal_Int32>(3);
-    xCellRangeBase->setPropertyValue(aRotateReference, aNewRotateReference);
-    uno::Any aRotateReferenceControllValue = xCellRangeBase->getPropertyValue(aRotateReference);
-    CPPUNIT_ASSERT(aRotateReferenceControllValue >>= aValue);
-    std::cout << "New RotateReference value: " << aValue << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("value has not been changed", aValue == 3);
-}
-
-uno::Reference< beans::XPropertySet > ScCellProperties::init()
-{
-    rtl::OUString aFileURL;
-    const rtl::OUString aFileBase(RTL_CONSTASCII_USTRINGPARAM("xcellrangesquery.ods"));
-    createFileURL(aFileBase, aFileURL);
-    if( !xComponent.is())
-        xComponent = loadFromDesktop(aFileURL);
-    uno::Reference< sheet::XSpreadsheetDocument> xDoc (xComponent, UNO_QUERY_THROW);
-    CPPUNIT_ASSERT(xDoc.is());
-
-    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
-    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(0), UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
-
-    uno::Reference< table::XCellRange > xCellRange(xSheet->getCellRangeByPosition(0,0,3,4), UNO_QUERY_THROW);
-    CPPUNIT_ASSERT(xCellRange.is());
-
-    uno::Reference< beans::XPropertySet > xReturn(xCellRange, UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT_MESSAGE("Could not create object of type XPropertySet", xReturn.is());
-    return xReturn;
-}
-
-void ScCellProperties::setUp()
-{
-    nTest += 1;
-    UnoApiTest::setUp();
-}
-
-void ScCellProperties::tearDown()
-{
-    if (nTest == NUMBER_OF_TESTS)
-    {
-        uno::Reference< util::XCloseable > xCloseable(xComponent, UNO_QUERY_THROW);
-        xCloseable->close( false );
-    }
-
-    UnoApiTest::tearDown();
-
-}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(ScCellProperties);
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/datapilotfieldobj.cxx b/sc/qa/extras/datapilotfieldobj.cxx
deleted file mode 100644
index 8ebc424..0000000
--- a/sc/qa/extras/datapilotfieldobj.cxx
+++ /dev/null
@@ -1,264 +0,0 @@
-/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
-#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
-#include <com/sun/star/sheet/XSpreadsheet.hpp>
-#include <com/sun/star/sheet/XDataPilotTablesSupplier.hpp>
-#include <com/sun/star/sheet/XDataPilotTables.hpp>
-#include <com/sun/star/sheet/XDataPilotDescriptor.hpp>
-#include <com/sun/star/beans/XPropertySet.hpp>
-#include <com/sun/star/sheet/DataPilotFieldSortInfo.hpp>
-#include <com/sun/star/sheet/DataPilotFieldSortMode.hpp>
-#include <com/sun/star/sheet/DataPilotFieldReferenceItemType.hpp>
-#include <com/sun/star/sheet/DataPilotFieldLayoutMode.hpp>
-#include <com/sun/star/sheet/DataPilotFieldLayoutInfo.hpp>
-#include <com/sun/star/sheet/DataPilotFieldReference.hpp>
-#include <com/sun/star/sheet/DataPilotFieldAutoShowInfo.hpp>
-
-#include <rtl/oustringostreaminserter.hxx>
-
-namespace ScDataPilotFieldObj {
-
-class ScDataPilotField : public UnoApiTest
-{
-
-    uno::Reference< beans::XPropertySet > init();
-
-    void testSortInfo();
-    void testLayoutInfo();
-    void testAutoShowInfo();
-    void testReference();
-    void testIsGroupField();
-
-    CPPUNIT_TEST_SUITE(ScDataPilotField);
-    CPPUNIT_TEST(testSortInfo);
-    CPPUNIT_TEST(testLayoutInfo);
-    CPPUNIT_TEST(testAutoShowInfo);
-    CPPUNIT_TEST(testReference);
-    CPPUNIT_TEST(testIsGroupField);
-    CPPUNIT_TEST_SUITE_END();
-};
-
-void ScDataPilotField::testSortInfo()
-{
-    uno::Reference< beans::XPropertySet> xPropSet = init();
-    sheet::DataPilotFieldSortInfo aSortInfoValue;
-    rtl::OUString aSortInfo(RTL_CONSTASCII_USTRINGPARAM("SortInfo"));
-    aSortInfoValue.Field = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Col1"));
-    aSortInfoValue.IsAscending = false;
-    aSortInfoValue.Mode = sheet::DataPilotFieldSortMode::MANUAL;
-    uno::Any xValue;
-    xValue <<= aSortInfoValue;
-    xPropSet->setPropertyValue(aSortInfo, xValue);
-
-    sheet::DataPilotFieldSortInfo aNewSortInfoValue;
-    xValue = xPropSet->getPropertyValue(aSortInfo);
-    CPPUNIT_ASSERT( xValue >>= aNewSortInfoValue );
-    CPPUNIT_ASSERT_MESSAGE("set value should be the same as got value", aNewSortInfoValue.Field == aSortInfoValue.Field
-            && aNewSortInfoValue.Mode == aSortInfoValue.Mode && aNewSortInfoValue.IsAscending == aSortInfoValue.IsAscending);
-
-    //setting HasSortInfo only makes sense for false, for true the uno implementation does nothing
-    sal_Bool bHasSortInfo;
-    rtl::OUString aHasSortInfo(RTL_CONSTASCII_USTRINGPARAM("HasSortInfo"));
-    xValue = xPropSet->getPropertyValue(aHasSortInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasSortInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have sort info", bHasSortInfo);
-
-    bHasSortInfo = false;
-    xValue <<= bHasSortInfo;
-    xPropSet->setPropertyValue(aHasSortInfo, xValue);
-
-    xValue = xPropSet->getPropertyValue(aHasSortInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasSortInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have no sort info", !bHasSortInfo);
-}
-
-void ScDataPilotField::testLayoutInfo()
-{
-    uno::Reference< beans::XPropertySet > xPropSet = init();
-    sheet::DataPilotFieldLayoutInfo aLayoutInfoValue;
-    rtl::OUString aLayoutInfo(RTL_CONSTASCII_USTRINGPARAM("LayoutInfo"));
-    aLayoutInfoValue.AddEmptyLines = false;
-    aLayoutInfoValue.LayoutMode = sheet::DataPilotFieldLayoutMode::OUTLINE_SUBTOTALS_BOTTOM;
-    uno::Any xValue;
-    xValue <<= aLayoutInfoValue;
-    xPropSet->setPropertyValue(aLayoutInfo, xValue);
-
-    sheet::DataPilotFieldLayoutInfo aNewLayoutInfoValue;
-    xValue = xPropSet->getPropertyValue(aLayoutInfo);
-    CPPUNIT_ASSERT( xValue >>= aNewLayoutInfoValue );
-    CPPUNIT_ASSERT_MESSAGE("set value should be the same as the got value", aNewLayoutInfoValue.LayoutMode == aLayoutInfoValue.LayoutMode &&
-            aNewLayoutInfoValue.AddEmptyLines == aLayoutInfoValue.AddEmptyLines);
-
-    //setting HasLayoutInfo only makes sense for false, tor true the uno implementation does nothing
-    sal_Bool bHasLayoutInfo;
-    rtl::OUString aHasLayoutInfo(RTL_CONSTASCII_USTRINGPARAM("HasLayoutInfo"));
-    xValue = xPropSet->getPropertyValue(aHasLayoutInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasLayoutInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have layout information", bHasLayoutInfo);
-
-    bHasLayoutInfo = false;
-    xValue <<= bHasLayoutInfo;
-    xPropSet->setPropertyValue(aHasLayoutInfo, xValue);
-
-    xValue = xPropSet->getPropertyValue(aHasLayoutInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasLayoutInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have no longer sort information", !bHasLayoutInfo);
-}
-
-void ScDataPilotField::testAutoShowInfo()
-{
-    uno::Reference< beans::XPropertySet > xPropSet = init();
-    sheet::DataPilotFieldAutoShowInfo aAutoShowInfoValue;
-    aAutoShowInfoValue.DataField = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Col1"));
-    aAutoShowInfoValue.IsEnabled = true;
-    rtl::OUString aAutoShowInfo(RTL_CONSTASCII_USTRINGPARAM("AutoShowInfo"));
-    uno::Any xValue;
-    xValue <<= aAutoShowInfoValue;
-    xPropSet->setPropertyValue(aAutoShowInfo, xValue);
-
-    sheet::DataPilotFieldAutoShowInfo aNewAutoShowInfoValue;
-    xValue = xPropSet->getPropertyValue(aAutoShowInfo);
-    CPPUNIT_ASSERT( xValue >>= aNewAutoShowInfoValue );
-    CPPUNIT_ASSERT_MESSAGE("set value should be the same as the got value", aNewAutoShowInfoValue.DataField == aAutoShowInfoValue.DataField &&
-            aNewAutoShowInfoValue.IsEnabled == aAutoShowInfoValue.IsEnabled);
-
-    //setting HasLayoutInfo only makes sense for false, tor true the uno implementation does nothing
-    sal_Bool bHasAutoShowInfo;
-    rtl::OUString aHasAutoShowInfo(RTL_CONSTASCII_USTRINGPARAM("HasAutoShowInfo"));
-    xValue = xPropSet->getPropertyValue(aHasAutoShowInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasAutoShowInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have AutoShow information", bHasAutoShowInfo);
-
-    bHasAutoShowInfo = false;
-    xValue <<= bHasAutoShowInfo;
-    xPropSet->setPropertyValue(aHasAutoShowInfo, xValue);
-
-    xValue = xPropSet->getPropertyValue(aHasAutoShowInfo);
-    CPPUNIT_ASSERT( xValue >>= bHasAutoShowInfo );
-    CPPUNIT_ASSERT_MESSAGE("should have no longer AutoShow information", !bHasAutoShowInfo);
-}
-
-void ScDataPilotField::testReference()
-{
-    uno::Reference< beans::XPropertySet > xPropSet = init();
-    sheet::DataPilotFieldReference aReferenceValue;
-    aReferenceValue.ReferenceField = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Col1"));
-    aReferenceValue.ReferenceItemType = sheet::DataPilotFieldReferenceItemType::NAMED;
-    rtl::OUString aReference(RTL_CONSTASCII_USTRINGPARAM("Reference"));
-    uno::Any xValue;
-    xValue <<= aReferenceValue;
-    xPropSet->setPropertyValue(aReference, xValue);
-
-    sheet::DataPilotFieldReference aNewReferenceValue;
-    xValue = xPropSet->getPropertyValue(aReference);
-    CPPUNIT_ASSERT( xValue >>= aNewReferenceValue );
-    CPPUNIT_ASSERT_MESSAGE("set value should be the same as the got value", aReferenceValue.ReferenceField == aNewReferenceValue.ReferenceField
-            && aReferenceValue.ReferenceItemType == aNewReferenceValue.ReferenceItemType);
-
-    //setting HasReference only makes sense for false, tor true the uno implementation does nothing
-    sal_Bool bHasReference;
-    rtl::OUString aHasReference(RTL_CONSTASCII_USTRINGPARAM("HasReference"));
-    xValue = xPropSet->getPropertyValue(aHasReference);
-    CPPUNIT_ASSERT( xValue >>= bHasReference );
-    CPPUNIT_ASSERT_MESSAGE("should have Reference information", bHasReference);
-
-    bHasReference = false;
-    xValue <<= bHasReference;
-    xPropSet->setPropertyValue(aHasReference, xValue);
-
-    xValue = xPropSet->getPropertyValue(aHasReference);
-    CPPUNIT_ASSERT( xValue >>= bHasReference );
-    CPPUNIT_ASSERT_MESSAGE("should have no longer reference information", !bHasReference);
-}
-
-void ScDataPilotField::testIsGroupField()
-{
-    uno::Reference< beans::XPropertySet > xPropSet = init();
-    uno::Any xValue;
-    rtl::OUString aIsGroupField(RTL_CONSTASCII_USTRINGPARAM("IsGroupField"));
-    sal_Bool bIsGroupField;
-
-    xValue = xPropSet->getPropertyValue(aIsGroupField);
-    CPPUNIT_ASSERT( xValue >>= bIsGroupField);
-    //only setting to false is supported
-    if (bIsGroupField)
-    {
-        bIsGroupField = false;
-        xValue <<= bIsGroupField;
-
-        xPropSet->setPropertyValue(aIsGroupField, xValue);
-        xValue = xPropSet->getPropertyValue(aIsGroupField);
-        CPPUNIT_ASSERT(xValue >>= bIsGroupField);
-        CPPUNIT_ASSERT_MESSAGE("setting IsGroupField is supported and should have happened", !bIsGroupField);
-    }
-    else
-        std::cout << "Could not test IsGroupField" << std::endl;
-}
-
-uno::Reference< beans::XPropertySet > ScDataPilotField::init()
-{
-    rtl::OUString aFileURL;
-    const rtl::OUString aFileBase(RTL_CONSTASCII_USTRINGPARAM("scdatapilotfieldobj.ods"));
-    createFileURL(aFileBase, aFileURL);
-    std::cout << rtl::OUStringToOString(aFileURL, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    static uno::Reference< lang::XComponent > xComponent;
-    if( !xComponent.is())
-        xComponent = loadFromDesktop(aFileURL);
-    uno::Reference< sheet::XSpreadsheetDocument> xDoc (xComponent, UNO_QUERY_THROW);
-    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
-    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(1), UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
-    uno::Reference< sheet::XDataPilotTablesSupplier > xDPTS(xSheet, UNO_QUERY_THROW);
-    CPPUNIT_ASSERT(xDPTS.is());
-    uno::Reference< sheet::XDataPilotTables > xDPT = xDPTS->getDataPilotTables();
-    CPPUNIT_ASSERT(xDPT.is());
-    uno::Sequence<rtl::OUString> aElementNames = xDPT->getElementNames();
-    for (int i = 0; i < aElementNames.getLength(); ++i)
-    {
-        std::cout << "PivotTable: " << aElementNames[i] << std::endl;
-    }
-
-    uno::Reference< sheet::XDataPilotDescriptor > xDPDsc(xDPT->getByName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataPilot1"))),UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT(xDPDsc.is());
-    uno::Reference< container::XIndexAccess > xIA( xDPDsc->getDataPilotFields(), UNO_QUERY_THROW);
-    uno::Reference< beans::XPropertySet > xReturnValue( xIA->getByIndex(0), UNO_QUERY_THROW);
-    CPPUNIT_ASSERT(xReturnValue.is());
-    return xReturnValue;
-}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotField);
-
-CPPUNIT_PLUGIN_IMPLEMENT();
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/sccellrangeobj.cxx b/sc/qa/extras/sccellrangeobj.cxx
new file mode 100644
index 0000000..20a191c
--- /dev/null
+++ b/sc/qa/extras/sccellrangeobj.cxx
@@ -0,0 +1,116 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xcellrangesquery.hxx>
+#include <test/sheet/cellproperties.hxx>
+
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <com/sun/star/table/XCellRange.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 8
+
+class ScCellRangeObj : public UnoApiTest, apitest::XCellRangesQuery, apitest::CellProperties
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+    virtual uno::Reference< uno::XInterface > init();
+
+    CPPUNIT_TEST_SUITE(ScCellRangeObj);
+    CPPUNIT_TEST(testQueryColumnDifference);
+    CPPUNIT_TEST(testQueryContentDifference);
+    CPPUNIT_TEST(testQueryEmptyCells);
+    //CPPUNIT_TEST(testQueryFormulaCells);
+    CPPUNIT_TEST(testQueryIntersection);
+    CPPUNIT_TEST(testQueryRowDifference);
+    CPPUNIT_TEST(testQueryVisibleCells);
+    CPPUNIT_TEST(testVertJustify);
+    CPPUNIT_TEST(testRotateReference);
+    CPPUNIT_TEST_SUITE_END();
+
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScCellRangeObj::nTest = 0;
+uno::Reference< lang::XComponent > ScCellRangeObj::mxComponent;
+
+uno::Reference< uno::XInterface > ScCellRangeObj::init()
+{
+    rtl::OUString aFileURL;
+    const rtl::OUString aFileBase(RTL_CONSTASCII_USTRINGPARAM("xcellrangesquery.ods"));
+    createFileURL(aFileBase, aFileURL);
+    std::cout << rtl::OUStringToOString(aFileURL, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
+    if( !mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    uno::Reference< sheet::XSpreadsheetDocument> xDoc (mxComponent, UNO_QUERY_THROW);
+    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
+    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(0), UNO_QUERY_THROW);
+
+    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
+
+    uno::Reference<table::XCellRange> xReturn(xSheet->getCellRangeByPosition(0,0,3,4), UNO_QUERY_THROW);
+
+    CPPUNIT_ASSERT_MESSAGE("Could not create object of type XCellRangesQuery", xReturn.is());
+    return xReturn;
+}
+
+void ScCellRangeObj::setUp()
+{
+    nTest++;
+    CPPUNIT_ASSERT(nTest <= NUMBER_OF_TESTS);
+    UnoApiTest::setUp();
+}
+
+void ScCellRangeObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScCellRangeObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/scdatabaserangeobj.cxx b/sc/qa/extras/scdatabaserangeobj.cxx
new file mode 100644
index 0000000..69a3d48
--- /dev/null
+++ b/sc/qa/extras/scdatabaserangeobj.cxx
@@ -0,0 +1,106 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xdatabaserange.hxx>
+
+#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/container/XNameAccess.hpp>
+#include <com/sun/star/sheet/XDatabaseRange.hpp>
+
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 3
+
+class ScDatabaseRangeObj : public UnoApiTest, apitest::XDatabaseRange
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+
+    virtual uno::Reference< uno::XInterface > init( const rtl::OUString& rDBName );
+
+    CPPUNIT_TEST_SUITE(ScDatabaseRangeObj);
+    CPPUNIT_TEST(testDataArea);
+    CPPUNIT_TEST(testGetSortDescriptor);
+    CPPUNIT_TEST(testGetSubtotalDescriptor);
+    CPPUNIT_TEST_SUITE_END();
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScDatabaseRangeObj::nTest = 0;
+uno::Reference< lang::XComponent > ScDatabaseRangeObj::mxComponent;
+
+uno::Reference< uno::XInterface > ScDatabaseRangeObj::init( const rtl::OUString& rDBName )
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("xdatabaserange.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+
+    uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW);
+    uno::Reference< beans::XPropertySet > xPropSet(xDoc, UNO_QUERY_THROW);
+    uno::Reference< container::XNameAccess > xNameAccess( xPropSet->getPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DatabaseRanges"))), UNO_QUERY_THROW);
+    uno::Reference< sheet::XDatabaseRange > xDBRange( xNameAccess->getByName(rDBName), UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xDBRange.is());
+    return xDBRange;
+}
+
+void ScDatabaseRangeObj::setUp()
+{
+    nTest++;
+    UnoApiTest::setUp();
+}
+
+void ScDatabaseRangeObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScDatabaseRangeObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/scdatapilotfieldobj.cxx b/sc/qa/extras/scdatapilotfieldobj.cxx
new file mode 100644
index 0000000..ff67e46
--- /dev/null
+++ b/sc/qa/extras/scdatapilotfieldobj.cxx
@@ -0,0 +1,123 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xdatapilotfieldgrouping.hxx>
+#include <test/sheet/datapilotfield.hxx>
+
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <com/sun/star/sheet/XDataPilotTablesSupplier.hpp>
+#include <com/sun/star/sheet/XDataPilotTables.hpp>
+#include <com/sun/star/sheet/XDataPilotDescriptor.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 6
+
+class ScDataPilotFieldObj : public UnoApiTest, apitest::XDataPilotFieldGrouping,
+                                apitest::DataPilotField
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+    virtual uno::Reference< uno::XInterface > init();
+
+    CPPUNIT_TEST_SUITE(ScDataPilotFieldObj);
+    CPPUNIT_TEST(testSortInfo);
+    CPPUNIT_TEST(testLayoutInfo);
+    CPPUNIT_TEST(testAutoShowInfo);
+    CPPUNIT_TEST(testReference);
+    CPPUNIT_TEST(testIsGroupField);
+    CPPUNIT_TEST(testCreateNameGroup);
+    // see fdo#
+    //CPPUNIT_TEST(testCreateDateGroup);
+    CPPUNIT_TEST_SUITE_END();
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScDataPilotFieldObj::nTest = 0;
+uno::Reference< lang::XComponent > ScDataPilotFieldObj::mxComponent;
+
+uno::Reference< uno::XInterface > ScDataPilotFieldObj::init()
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("scdatapilotfieldobj.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+
+    uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW);
+    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
+    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(1), UNO_QUERY_THROW);
+
+    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
+    uno::Reference< sheet::XDataPilotTablesSupplier > xDPTS(xSheet, UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xDPTS.is());
+    uno::Reference< sheet::XDataPilotTables > xDPT = xDPTS->getDataPilotTables();
+    CPPUNIT_ASSERT(xDPT.is());
+    uno::Sequence<rtl::OUString> aElementNames = xDPT->getElementNames();
+
+    uno::Reference< sheet::XDataPilotDescriptor > xDPDsc(xDPT->getByName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataPilot1"))),UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xDPDsc.is());
+    uno::Reference< container::XIndexAccess > xIA( xDPDsc->getDataPilotFields(), UNO_QUERY_THROW);
+    uno::Reference< uno::XInterface > xReturnValue( xIA->getByIndex(0), UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xReturnValue.is());
+    return xReturnValue;
+}
+
+void ScDataPilotFieldObj::setUp()
+{
+    nTest++;
+    UnoApiTest::setUp();
+}
+
+void ScDataPilotFieldObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotFieldObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/scdatapilottableobj.cxx b/sc/qa/extras/scdatapilottableobj.cxx
new file mode 100644
index 0000000..6d07b8f
--- /dev/null
+++ b/sc/qa/extras/scdatapilottableobj.cxx
@@ -0,0 +1,129 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xdatapilottable.hxx>
+#include <test/sheet/xdatapilotdescriptor.hxx>
+
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+#include <com/sun/star/sheet/XDataPilotTablesSupplier.hpp>
+#include <com/sun/star/sheet/XDataPilotTables.hpp>
+#include <com/sun/star/sheet/XDataPilotTable.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 9
+
+class ScDataPilotTableObj : public UnoApiTest, apitest::XDataPilotDescriptor, apitest::XDataPilotTable
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+    virtual uno::Reference< uno::XInterface > init();
+
+    CPPUNIT_TEST_SUITE(ScDataPilotTableObj);
+    //CPPUNIT_TEST(testRefresh);
+    //CPPUNIT_TEST(testGetHiddenFields);
+    CPPUNIT_TEST(testGetOutputRange);
+    CPPUNIT_TEST(testSourceRange);
+    CPPUNIT_TEST(testTag);
+    CPPUNIT_TEST(testGetFilterDescriptor);
+    CPPUNIT_TEST(testGetDataPilotFields);
+    CPPUNIT_TEST(testGetColumnFields);
+    CPPUNIT_TEST(testGetRowFields);
+    CPPUNIT_TEST(testGetPageFields);
+    CPPUNIT_TEST(testGetDataFields);
+    CPPUNIT_TEST_SUITE_END();
+
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScDataPilotTableObj::nTest = 0;
+uno::Reference< lang::XComponent > ScDataPilotTableObj::mxComponent;
+
+uno::Reference< uno::XInterface > ScDataPilotTableObj::init()
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ScDataPilotTableObj.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+
+    uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW);
+    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
+    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(0), UNO_QUERY_THROW);
+
+    // set variables from xdatapilottable.[ch]xx
+    xCellForChange = xSheet->getCellByPosition( 1, 5 );
+    xCellForCheck = xSheet->getCellByPosition( 7, 11 );
+    CPPUNIT_ASSERT(xCellForCheck.is());
+    CPPUNIT_ASSERT(xCellForChange.is());
+
+    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
+    uno::Reference< sheet::XDataPilotTablesSupplier > xDPTS(xSheet, UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xDPTS.is());
+    uno::Reference< sheet::XDataPilotTables > xDPT = xDPTS->getDataPilotTables();
+    CPPUNIT_ASSERT(xDPT.is());
+
+    uno::Reference< sheet::XDataPilotTable > xDPTable(xDPT->getByName(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataPilotTable"))),UNO_QUERY_THROW);
+
+    CPPUNIT_ASSERT(xDPTable.is());
+    return xDPTable;
+}
+
+void ScDataPilotTableObj::setUp()
+{
+    nTest++;
+    UnoApiTest::setUp();
+}
+
+void ScDataPilotTableObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScDataPilotTableObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/scnamedrangeobj.cxx b/sc/qa/extras/scnamedrangeobj.cxx
new file mode 100644
index 0000000..2d72402
--- /dev/null
+++ b/sc/qa/extras/scnamedrangeobj.cxx
@@ -0,0 +1,117 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/sheet/xnamedrange.hxx>
+#include <test/unoapi_test.hxx>
+
+#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/sheet/XSpreadsheet.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 6
+
+class ScNamedRangeObj : public UnoApiTest, apitest::XNamedRange
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+
+    virtual uno::Reference< uno::XInterface > init();
+    virtual uno::Reference< sheet::XNamedRange > getNamedRange(const rtl::OUString& rRangeName);
+
+    CPPUNIT_TEST_SUITE(ScNamedRangeObj);
+    CPPUNIT_TEST(testGetContent);
+    CPPUNIT_TEST(testSetContent);
+    CPPUNIT_TEST(testGetType);
+    CPPUNIT_TEST(testSetType);
+    CPPUNIT_TEST(testGetReferencePosition);
+    CPPUNIT_TEST(testSetReferencePosition);
+    CPPUNIT_TEST_SUITE_END();
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScNamedRangeObj::nTest = 0;
+uno::Reference< lang::XComponent > ScNamedRangeObj::mxComponent;
+
+uno::Reference< sheet::XNamedRange> ScNamedRangeObj::getNamedRange(const rtl::OUString& rRangeName)
+{
+    uno::Reference< container::XNameAccess > xNamedAccess(init(), UNO_QUERY_THROW);
+    uno::Reference< sheet::XNamedRange > xNamedRange(xNamedAccess->getByName(rRangeName), UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xNamedRange.is());
+
+    return xNamedRange;
+}
+
+uno::Reference< uno::XInterface > ScNamedRangeObj::init()
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("rangenames.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+
+    uno::Reference< beans::XPropertySet > xPropSet (mxComponent, UNO_QUERY_THROW);
+    rtl::OUString aNamedRangesPropertyString(RTL_CONSTASCII_USTRINGPARAM("NamedRanges"));
+    uno::Reference< container::XNameAccess > xNamedRangesNameAccess(xPropSet->getPropertyValue(aNamedRangesPropertyString), UNO_QUERY_THROW);
+    CPPUNIT_ASSERT(xNamedRangesNameAccess.is());
+
+    return xNamedRangesNameAccess;
+}
+
+void ScNamedRangeObj::setUp()
+{
+    nTest++;
+    UnoApiTest::setUp();
+}
+
+void ScNamedRangeObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScNamedRangeObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/scnamedrangesobj.cxx b/sc/qa/extras/scnamedrangesobj.cxx
new file mode 100644
index 0000000..f6d2322
--- /dev/null
+++ b/sc/qa/extras/scnamedrangesobj.cxx
@@ -0,0 +1,110 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xnamedranges.hxx>
+
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/sheet/XNamedRanges.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 3
+
+class ScNamedRangesObj : public UnoApiTest, apitest::XNamedRanges
+{
+public:
+    virtual void setUp();
+    virtual void tearDown();
+
+    virtual uno::Reference< uno::XInterface > init(sal_Int32 nSheet);
+
+    CPPUNIT_TEST_SUITE(ScNamedRangesObj);
+    CPPUNIT_TEST(testAddNewByName);
+    CPPUNIT_TEST(testAddNewFromTitles);
+    //CPPUNIT_TEST_EXCEPTION(testRemoveByName, uno::RuntimeException);
+    CPPUNIT_TEST(testOutputList);
+    CPPUNIT_TEST_SUITE_END();
+
+private:
+    static sal_Int32 nTest;
+    static uno::Reference< lang::XComponent > mxComponent;
+};
+
+sal_Int32 ScNamedRangesObj::nTest = 0;
+uno::Reference< lang::XComponent > ScNamedRangesObj::mxComponent;
+
+uno::Reference< uno::XInterface > ScNamedRangesObj::init(sal_Int32 nSheet)
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("rangenames.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+
+    uno::Reference< beans::XPropertySet > xPropSet (mxComponent, UNO_QUERY_THROW);
+    rtl::OUString aNamedRangesPropertyString(RTL_CONSTASCII_USTRINGPARAM("NamedRanges"));
+    uno::Reference< sheet::XNamedRanges > xNamedRanges(xPropSet->getPropertyValue(aNamedRangesPropertyString), UNO_QUERY_THROW);
+
+    //set value from xnamedranges.hxx
+    uno::Reference< sheet::XSpreadsheetDocument > xDoc(mxComponent, UNO_QUERY_THROW);
+    uno::Reference< container::XIndexAccess > xIndexAccess(xDoc->getSheets(), UNO_QUERY_THROW);
+    xSheet = uno::Reference< sheet::XSpreadsheet >(xIndexAccess->getByIndex(nSheet),UNO_QUERY_THROW);
+
+    return xNamedRanges;
+}
+
+void ScNamedRangesObj::setUp()
+{
+    nTest++;
+    UnoApiTest::setUp();
+}
+
+void ScNamedRangesObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScNamedRangesObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/sctablesheetsobj.cxx b/sc/qa/extras/sctablesheetsobj.cxx
new file mode 100644
index 0000000..8b0b5e9
--- /dev/null
+++ b/sc/qa/extras/sctablesheetsobj.cxx
@@ -0,0 +1,138 @@
+/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
+#include <test/sheet/xspreadsheets2.hxx>
+#include <test/container/xnamecontainer.hxx>
+
+#include <com/sun/star/beans/XPropertySet.hpp>
+#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
+
+namespace sc_apitest {
+
+#define NUMBER_OF_TESTS 13
+
+class ScTableSheetsObj : public UnoApiTest, public ::apitest::XSpreadsheets2, apitest::XNameContainer
+{
+public:
+    ScTableSheetsObj();
+
+    virtual void setUp();
+    virtual void tearDown();
+
+    CPPUNIT_TEST_SUITE(ScTableSheetsObj);
+    CPPUNIT_TEST(testImportValue);
+    CPPUNIT_TEST(testImportString);
+    CPPUNIT_TEST(testImportedSheetNameAndIndex);
+    CPPUNIT_TEST(testImportString);
+    CPPUNIT_TEST(testImportValue);
+    CPPUNIT_TEST(testImportFormulaBasicMath);
+    CPPUNIT_TEST(testImportFormulaWithNamedRange);
+    CPPUNIT_TEST(testImportOverExistingNamedRange);
+    CPPUNIT_TEST(testImportNamedRangeDefinedInSource);
+    CPPUNIT_TEST(testImportNamedRangeRedefinedInSource);
+    CPPUNIT_TEST(testImportNewNamedRange);
+    CPPUNIT_TEST(testImportCellStyle);
+    CPPUNIT_TEST(testRemoveByName);
+    CPPUNIT_TEST_SUITE_END();
+
+    virtual uno::Reference< lang::XComponent > getComponent();
+    virtual void createFileURL(const rtl::OUString& rFileBase, rtl::OUString& rFileURL);
+    virtual uno::Reference< lang::XComponent > loadFromDesktop(const rtl::OUString& rString);
+    virtual uno::Reference< uno::XInterface > init();
+protected:
+    static uno::Reference< lang::XComponent > mxComponent;
+    static sal_Int32 nTest;
+};
+
+uno::Reference< lang::XComponent > ScTableSheetsObj::mxComponent;
+sal_Int32 ScTableSheetsObj::nTest = 0;
+
+ScTableSheetsObj::ScTableSheetsObj():
+            apitest::XNameContainer(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Sheet2")))
+{
+
+}
+
+uno::Reference< lang::XComponent > ScTableSheetsObj::getComponent()
+{
+    return mxComponent;
+}
+
+void ScTableSheetsObj::createFileURL(const rtl::OUString& rFileBase, rtl::OUString& rFileURL)
+{
+    UnoApiTest::createFileURL(rFileBase, rFileURL);
+}
+
+uno::Reference< lang::XComponent > ScTableSheetsObj::loadFromDesktop(const rtl::OUString& rString)
+{
+    return UnoApiTest::loadFromDesktop(rString);
+}
+
+uno::Reference< uno::XInterface > ScTableSheetsObj::init()
+{
+    rtl::OUString aFileURL;
+    createFileURL(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("rangenamessrc.ods")), aFileURL);
+    if(!mxComponent.is())
+        mxComponent = loadFromDesktop(aFileURL);
+    CPPUNIT_ASSERT(mxComponent.is());
+    xDocument = uno::Reference< sheet::XSpreadsheetDocument >(mxComponent, UNO_QUERY_THROW);
+    uno::Reference< uno::XInterface > xReturn( xDocument->getSheets(), UNO_QUERY_THROW);
+
+    return xReturn;
+}
+
+void ScTableSheetsObj::setUp()
+{
+    nTest++;
+    CPPUNIT_ASSERT(nTest <= NUMBER_OF_TESTS);
+    UnoApiTest::setUp();
+}
+
+void ScTableSheetsObj::tearDown()
+{
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        closeDocument(mxComponent);
+    }
+
+    UnoApiTest::tearDown();
+
+    if (nTest == NUMBER_OF_TESTS)
+    {
+        mxDesktop->terminate();
+    }
+}
+
+CPPUNIT_TEST_SUITE_REGISTRATION(ScTableSheetsObj);
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/tableautoformatfield.cxx b/sc/qa/extras/tableautoformatfield.cxx
deleted file mode 100644
index ac0ad8c..0000000
--- a/sc/qa/extras/tableautoformatfield.cxx
+++ /dev/null
@@ -1,131 +0,0 @@
-/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
-
-#include <com/sun/star/beans/XPropertySet.hpp>
-
-#include <iostream>
-
-namespace ScAutoFormatFieldObj {
-
-#define NUMBER_OF_TESTS 2
-
-class ScTableAutoFormatField : public UnoApiTest
-{
-public:
-
-    virtual void setUp();
-    virtual void tearDown();
-
-    uno::Reference< beans::XPropertySet > init();    void testRotateReference();
-    void testVertJustify();
-
-    CPPUNIT_TEST_SUITE(ScTableAutoFormatField);
-    CPPUNIT_TEST(testRotateReference);
-    CPPUNIT_TEST(testVertJustify);
-    CPPUNIT_TEST_SUITE_END();
-
-private:
-
-    static int nTest;
-};
-
-int ScTableAutoFormatField::nTest = 0;
-
-uno::Reference< beans::XPropertySet > ScTableAutoFormatField::init()
-{
-    uno::Reference< container::XIndexAccess > xAutoFormatFields( m_xSFactory->createInstance(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sheet.TableAutoFormats"))), UNO_QUERY_THROW );
-    CPPUNIT_ASSERT(xAutoFormatFields.is());
-    uno::Reference< container::XIndexAccess > xIndex( xAutoFormatFields->getByIndex(0), UNO_QUERY_THROW );
-    CPPUNIT_ASSERT(xIndex.is());
-    uno::Reference< beans::XPropertySet > xReturn( xIndex->getByIndex(0), UNO_QUERY_THROW );
-    CPPUNIT_ASSERT_MESSAGE("could not create table auto formats", xReturn.is());
-    return xReturn;
-}
-
-void ScTableAutoFormatField::testRotateReference()
-{
-    uno::Reference< beans::XPropertySet > xTableAutoFormatField = init();
-    rtl::OUString aRotateReference(RTL_CONSTASCII_USTRINGPARAM("RotateReference"));
-    uno::Any aOldRotateReference = xTableAutoFormatField->getPropertyValue(aRotateReference);
-    sal_Int32 aValue = 0;
-    CPPUNIT_ASSERT(aOldRotateReference >>= aValue);
-    std::cout << "Old RotateReferene Value: " << aValue << std::endl;
-
-    uno::Any aNewRotateReference;
-    aNewRotateReference <<= static_cast<sal_Int32>(3);
-    xTableAutoFormatField->setPropertyValue(aRotateReference, aNewRotateReference);
-    uno::Any aRotateReferenceControllValue = xTableAutoFormatField->getPropertyValue(aRotateReference);
-    CPPUNIT_ASSERT(aRotateReferenceControllValue >>= aValue);
-    std::cout << "New VertJustify value: " << aValue << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("value has not been changed", aValue == 3);
-}
-
-void ScTableAutoFormatField::testVertJustify()
-{
-    uno::Reference< beans::XPropertySet > xTableAutoFormatField = init();
-    rtl::OUString aVertJustify(RTL_CONSTASCII_USTRINGPARAM("VertJustify"));
-    uno::Any aOldVertJustify = xTableAutoFormatField->getPropertyValue(aVertJustify);
-    sal_Int32 aValue = 0;
-    CPPUNIT_ASSERT(aOldVertJustify >>= aValue);
-    std::cout << "Old VertJustify value: " << aValue << std::endl;
-
-    uno::Any aNewVertJustify;
-    aNewVertJustify <<= static_cast<sal_Int32>(3);
-    xTableAutoFormatField->setPropertyValue(aVertJustify, aNewVertJustify);
-    uno::Any aVertJustifyControllValue = xTableAutoFormatField->getPropertyValue(aVertJustify);
-    CPPUNIT_ASSERT(aVertJustifyControllValue >>= aValue);
-    std::cout << "New VertJustify value: " << aValue << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("value has not been changed", aValue == 3);
-}
-
-void ScTableAutoFormatField::setUp()
-{
-    nTest += 1;
-    UnoApiTest::setUp();
-}
-
-void ScTableAutoFormatField::tearDown()
-{
-    UnoApiTest::tearDown();
-
-    if (nTest == NUMBER_OF_TESTS)
-    {
-        mxDesktop->terminate();
-        uno::Reference< lang::XComponent>(m_xContext, UNO_QUERY_THROW)->dispose();
-    }
-}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(ScTableAutoFormatField);
-
-CPPUNIT_PLUGIN_IMPLEMENT();
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/testdocuments/rangenamessrc.ods b/sc/qa/extras/testdocuments/rangenamessrc.ods
index f6546e9..d22702b 100644
Binary files a/sc/qa/extras/testdocuments/rangenamessrc.ods and b/sc/qa/extras/testdocuments/rangenamessrc.ods differ
diff --git a/sc/qa/extras/xcellrangesquery.cxx b/sc/qa/extras/xcellrangesquery.cxx
deleted file mode 100644
index a5a5a6f..0000000
--- a/sc/qa/extras/xcellrangesquery.cxx
+++ /dev/null
@@ -1,196 +0,0 @@
-/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
-
-#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
-#include <com/sun/star/sheet/XSpreadsheet.hpp>
-#include <com/sun/star/sheet/XCellRangesQuery.hpp>
-#include <com/sun/star/sheet/XSheetCellRanges.hpp>
-#include <com/sun/star/table/CellAddress.hpp>
-#include <com/sun/star/sheet/CellFlags.hpp>
-#include <com/sun/star/util/XCloseable.hpp>
-
-using namespace com::sun::star;
-
-
-namespace ScCellRangeBase {
-
-#define NUMBER_OF_TESTS 5
-
-class ScXCellRangesQuery : public UnoApiTest
-{
-public:
-
-    virtual void setUp();
-    virtual void tearDown();
-
-    //Testcases
-    void testQueryColumnDifference();
-    void testQueryContentDifference();
-    void testQueryEmptyCells();
-    void testQueryFormulaCells();
-    void testQueryIntersection();
-    void testQueryRowDifference();
-    void testQueryVisibleCells();
-
-    CPPUNIT_TEST_SUITE(ScXCellRangesQuery);
-    CPPUNIT_TEST(testQueryColumnDifference);
-    CPPUNIT_TEST(testQueryContentDifference);
-    CPPUNIT_TEST(testQueryEmptyCells);
-    //looks broken
-    //CPPUNIT_TEST(testQueryFormulaCells);
-    CPPUNIT_TEST(testQueryIntersection);
-    CPPUNIT_TEST(testQueryRowDifference);
-    CPPUNIT_TEST_SUITE_END();
-
-private:
-    uno::Reference<sheet::XCellRangesQuery> init();
-
-    static int nTest;
-    static uno::Reference< lang::XComponent > xComponent;
-};
-
-int ScXCellRangesQuery::nTest = 0;
-uno::Reference< lang::XComponent > ScXCellRangesQuery::xComponent;
-
-uno::Reference<sheet::XCellRangesQuery> ScXCellRangesQuery::init()
-{
-    rtl::OUString aFileURL;
-    const rtl::OUString aFileBase(RTL_CONSTASCII_USTRINGPARAM("xcellrangesquery.ods"));
-    createFileURL(aFileBase, aFileURL);
-    std::cout << rtl::OUStringToOString(aFileURL, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    if( !xComponent.is())
-        xComponent = loadFromDesktop(aFileURL);
-    uno::Reference< sheet::XSpreadsheetDocument> xDoc (xComponent, UNO_QUERY_THROW);
-    uno::Reference< container::XIndexAccess > xIndex (xDoc->getSheets(), UNO_QUERY_THROW);
-    uno::Reference< sheet::XSpreadsheet > xSheet( xIndex->getByIndex(0), UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT_MESSAGE("Could not create interface of type XSpreadsheet", xSheet.is());
-
-    uno::Reference<sheet::XCellRangesQuery> xReturn(xSheet->getCellRangeByPosition(0,0,3,4), UNO_QUERY_THROW);
-
-    CPPUNIT_ASSERT_MESSAGE("Could not create object of type XCellRangesQuery", xReturn.is());
-    return xReturn;
-}
-
-void ScXCellRangesQuery::testQueryColumnDifference()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.B1:C1,Sheet1.B3:C5"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryColumnDifferences(table::CellAddress(0, 1, 1));
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryColumnDifference: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryColumnDifference", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryContentDifference()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.B2:B3"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryContentCells(sheet::CellFlags::VALUE);
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryContentDifference: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryContentDifference", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryEmptyCells()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.A1:A5,Sheet1.B1:C1,Sheet1.B5,Sheet1.C3:C5,Sheet1.D1:D5"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryEmptyCells();
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryEmptyCells: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryEmptyCells", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryFormulaCells()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.C2"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryFormulaCells(sheet::CellFlags::FORMULA);
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryFormulaCells: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryFormulaCells", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryIntersection()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.D4:D5"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryIntersection(table::CellRangeAddress(0,3,3,7,7));
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryIntersection: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryFormulaCells", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryRowDifference()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.A2:A4,Sheet1.C2:D4"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryRowDifferences(table::CellAddress(0,1,1));
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryRowDifference: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryFormulaCells", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::testQueryVisibleCells()
-{
-    rtl::OUString aExpected(RTL_CONSTASCII_USTRINGPARAM("Sheet1.A2"));
-    uno::Reference<sheet::XCellRangesQuery> xCellRangesQuery = init();
-    uno::Reference<sheet::XSheetCellRanges> xRanges = xCellRangesQuery->queryVisibleCells();
-    rtl::OUString aResult = xRanges->getRangeAddressesAsString();
-    std::cout << "testQueryVisibleCells: Result: " << rtl::OUStringToOString(aResult, RTL_TEXTENCODING_UTF8).getStr() << std::endl;
-    CPPUNIT_ASSERT_MESSAGE("testQueryFormulaCells", aResult == aExpected);
-}
-
-void ScXCellRangesQuery::setUp()
-{
-    nTest += 1;
-    UnoApiTest::setUp();
-}
-
-void ScXCellRangesQuery::tearDown()
-{
-    if (nTest == NUMBER_OF_TESTS)
-    {
-        uno::Reference< util::XCloseable > xCloseable(xComponent, UNO_QUERY_THROW);
-        xCloseable->close( false );
-    }
-
-    UnoApiTest::tearDown();
-
-}
-
-CPPUNIT_TEST_SUITE_REGISTRATION(ScXCellRangesQuery);
-
-CPPUNIT_PLUGIN_IMPLEMENT();
-
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/qa/extras/xdatabaserange.cxx b/sc/qa/extras/xdatabaserange.cxx
deleted file mode 100644
index 22a2680..0000000
--- a/sc/qa/extras/xdatabaserange.cxx
+++ /dev/null
@@ -1,209 +0,0 @@
-/* -*- 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 Markus Mohrhard <markus.mohrhard at googlemail.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 <test/unoapi_test.hxx>
-#include <com/sun/star/sheet/XSpreadsheetDocument.hpp>
-#include <com/sun/star/sheet/XSpreadsheet.hpp>
-#include <com/sun/star/sheet/XSubTotalDescriptor.hpp>
-#include <com/sun/star/beans/PropertyValue.hpp>
-#include <com/sun/star/sheet/XDatabaseRange.hpp>
-#include <com/sun/star/sheet/XDatabaseRanges.hpp>
-#include <com/sun/star/table/CellRangeAddress.hpp>
-#include <com/sun/star/util/XCloseable.hpp>
-#include <com/sun/star/beans/XPropertySet.hpp>
-#include <rtl/oustringostreaminserter.hxx>
-
-namespace ScDatabaseRangeObj {
-
-#define NUMBER_OF_TESTS 3
-
-class ScXDatabaseRange : public UnoApiTest
-{
-    virtual void setUp();
-    virtual void tearDown();
-
-    void testDataArea();
-    void testGetSortDescriptor();
-    void testGetSubtotalDescriptor();
-
-    CPPUNIT_TEST_SUITE(ScXDatabaseRange);
-    CPPUNIT_TEST(testDataArea);
-    CPPUNIT_TEST(testGetSortDescriptor);
-    CPPUNIT_TEST(testGetSubtotalDescriptor);
-    CPPUNIT_TEST_SUITE_END();
-private:
-    uno::Reference< sheet::XDatabaseRange > init(const rtl::OUString& rName);
-
-    static int nTest;
-    static uno::Reference< lang::XComponent > xComponent;
-};
-
-int ScXDatabaseRange::nTest = 0;
-uno::Reference< lang::XComponent > ScXDatabaseRange::xComponent;
-
-/**
- * tests setDataArea and getDataArea
- */
-void ScXDatabaseRange::testDataArea()
-{
-    uno::Reference< sheet::XDatabaseRange > xDBRange = init(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataArea")));
-
-    table::CellRangeAddress aCellAddress;
-    aCellAddress.Sheet = 0;
-    aCellAddress.StartColumn = 1;
-    aCellAddress.EndColumn = 4;
-    aCellAddress.StartRow = 2;
-    aCellAddress.EndRow = 5;
-    xDBRange->setDataArea(aCellAddress);
-    table::CellRangeAddress aValue;
-    aValue = xDBRange->getDataArea();

... etc. - the rest is truncated


More information about the Libreoffice-commits mailing list