diff options
author | Jens Carl <j.carl43@gmx.de> | 2017-08-07 00:23:25 +0000 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2017-08-08 07:25:33 +0200 |
commit | 27cbca2c8dccbbb299621b49e5ffd836188202f0 (patch) | |
tree | fd6eec5f648286c0f4463b41891b759013571fc5 /sc | |
parent | 0bd57d62d0f15eced0e99097d9f46a86f177e9a1 (diff) |
tdf#45904 Move Java _XUsedAreaCursor tests to C++
Change-Id: I6a288fa333d6805540156f63040468f07967c0c6
Reviewed-on: https://gerrit.libreoffice.org/40817
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/qa/extras/sccellcursorobj.cxx | 16 | ||||
-rw-r--r-- | sc/qa/extras/testdocuments/ScCellCursorObj.ods | bin | 7451 -> 7639 bytes |
2 files changed, 11 insertions, 5 deletions
diff --git a/sc/qa/extras/sccellcursorobj.cxx b/sc/qa/extras/sccellcursorobj.cxx index ade41a77e375..7450034b7705 100644 --- a/sc/qa/extras/sccellcursorobj.cxx +++ b/sc/qa/extras/sccellcursorobj.cxx @@ -9,8 +9,8 @@ #include <test/calc_unoapi_test.hxx> #include <test/sheet/xcellseries.hxx> +#include <test/sheet/xusedareacursor.hxx> -#include <com/sun/star/table/XCellCursor.hpp> #include <com/sun/star/sheet/XSpreadsheetDocument.hpp> #include <com/sun/star/sheet/XSpreadsheet.hpp> @@ -19,9 +19,9 @@ using namespace css::uno; namespace sc_apitest { -#define NUMBER_OF_TESTS 2 +#define NUMBER_OF_TESTS 4 -class ScCellCursorObj : public CalcUnoApiTest, private apitest::XCellSeries +class ScCellCursorObj : public CalcUnoApiTest, private apitest::XCellSeries, public apitest::XUsedAreaCursor { public: ScCellCursorObj(); @@ -31,8 +31,15 @@ public: virtual uno::Reference< uno::XInterface > init() override; CPPUNIT_TEST_SUITE(ScCellCursorObj); + + // XUsedAreaCursor + CPPUNIT_TEST(testGotoStartOfUsedArea); + CPPUNIT_TEST(testGotoEndOfUsedArea); + + // XCellSeries CPPUNIT_TEST(testFillAuto); CPPUNIT_TEST(testFillSeries); + CPPUNIT_TEST_SUITE_END(); private: @@ -60,9 +67,8 @@ uno::Reference< uno::XInterface > ScCellCursorObj::init() 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); - uno::Reference< table::XCellCursor > xCellCursor( xSheet->createCursor(), UNO_QUERY_THROW); - return xCellCursor; + return xSheet; } void ScCellCursorObj::setUp() diff --git a/sc/qa/extras/testdocuments/ScCellCursorObj.ods b/sc/qa/extras/testdocuments/ScCellCursorObj.ods Binary files differindex fbb054f59f2e..46d8090ec5d2 100644 --- a/sc/qa/extras/testdocuments/ScCellCursorObj.ods +++ b/sc/qa/extras/testdocuments/ScCellCursorObj.ods |