summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJens Carl <j.carl43@gmx.de>2017-08-08 08:53:00 +0000
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-08-18 19:48:26 +0200
commit70027414b3ae0c460b0d398fccde092750af47fd (patch)
treef2b6b55e906fbf7d217c9b22100d32271cec9dfc /test
parentaee0dfee2cbc313b9baf63cdb24af5a676c5eee2 (diff)
tdf#45904 Move Java _XViewFreezable tests to C++
Change-Id: I75a0363304dbaaeb5988f2ec027d8211f4e01a4f Reviewed-on: https://gerrit.libreoffice.org/40872 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'test')
-rw-r--r--test/Library_subsequenttest.mk1
-rw-r--r--test/source/sheet/xviewfreezable.cxx33
2 files changed, 34 insertions, 0 deletions
diff --git a/test/Library_subsequenttest.mk b/test/Library_subsequenttest.mk
index e1c6c3c1f064..bc442ba621b9 100644
--- a/test/Library_subsequenttest.mk
+++ b/test/Library_subsequenttest.mk
@@ -68,6 +68,7 @@ $(eval $(call gb_Library_add_exception_objects,subsequenttest,\
test/source/sheet/xstyleloader \
test/source/sheet/xusedareacursor \
test/source/sheet/xviewpane \
+ test/source/sheet/xviewfreezable \
test/source/sheet/xviewsplitable \
test/source/text/xtext \
test/source/text/xtextfield \
diff --git a/test/source/sheet/xviewfreezable.cxx b/test/source/sheet/xviewfreezable.cxx
new file mode 100644
index 000000000000..89b8d06099ff
--- /dev/null
+++ b/test/source/sheet/xviewfreezable.cxx
@@ -0,0 +1,33 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include <test/sheet/xviewfreezable.hxx>
+
+#include <com/sun/star/sheet/XViewFreezable.hpp>
+
+#include "cppunit/extensions/HelperMacros.h"
+
+using namespace com::sun::star;
+using namespace com::sun::star::uno;
+
+namespace apitest {
+
+void XViewFreezable::testFreeze()
+{
+ uno::Reference< sheet::XViewFreezable > xViewFreezable(init(), UNO_QUERY_THROW);
+
+ CPPUNIT_ASSERT_MESSAGE("View has already frozen panes", !xViewFreezable->hasFrozenPanes());
+
+ xViewFreezable->freezeAtPosition(1,1);
+ CPPUNIT_ASSERT_MESSAGE("Unable to freeze pane", xViewFreezable->hasFrozenPanes());
+}
+
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */