[Libreoffice-commits] .: extensions/CppunitTest_extensions_test_update.mk extensions/Makefile extensions/Module_extensions.mk extensions/prj extensions/qa
Jan Holesovsky
kendy at kemper.freedesktop.org
Mon Oct 17 02:38:24 PDT 2011
extensions/CppunitTest_extensions_test_update.mk | 51 ++++++++++++++++++
extensions/Makefile | 39 ++++++++++++++
extensions/Module_extensions.mk | 32 +++++++++++
extensions/prj/build.lst | 2
extensions/qa/update/test_update.cxx | 62 +++++++++++++++++++++++
5 files changed, 185 insertions(+), 1 deletion(-)
New commits:
commit 17523de685d0c4b06f9be02c02788583e9fd221e
Author: Jan Holesovsky <kendy at suse.cz>
Date: Mon Oct 17 11:37:56 2011 +0200
Skeleton of the unit test for updates.
diff --git a/extensions/CppunitTest_extensions_test_update.mk b/extensions/CppunitTest_extensions_test_update.mk
new file mode 100644
index 0000000..b5703c0
--- /dev/null
+++ b/extensions/CppunitTest_extensions_test_update.mk
@@ -0,0 +1,51 @@
+#
+# 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 Jan Holesovsky <kendy at suse.cz> (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.
+#
+
+$(eval $(call gb_CppunitTest_CppunitTest,extensions_test_update))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,extensions_test_update, \
+ extensions/qa/update/test_update \
+))
+
+$(eval $(call gb_CppunitTest_add_linked_libs,extensions_test_update, \
+ cppu \
+ cppuhelper \
+ sal \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_CppunitTest_set_include,extensions_test_update,\
+ $$(INCLUDE) \
+ -I$(OUTDIR)/inc \
+))
+
+$(eval $(call gb_CppunitTest_add_api,extensions_test_update,\
+ offapi \
+ udkapi \
+))
+
+# vim:set shiftwidth=4 softtabstop=4 noexpandtab:
diff --git a/extensions/Makefile b/extensions/Makefile
new file mode 100644
index 0000000..8d71119
--- /dev/null
+++ b/extensions/Makefile
@@ -0,0 +1,39 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+ifeq ($(strip $(SOLARENV)),)
+$(error No environment set!)
+endif
+
+gb_PARTIALBUILD := T
+GBUILDDIR := $(SOLARENV)/gbuild
+include $(GBUILDDIR)/gbuild.mk
+
+$(eval $(call gb_Module_make_global_targets,$(shell ls $(dir $(realpath $(firstword $(MAKEFILE_LIST))))/Module*.mk)))
+
+# vim: set noet sw=4 ts=4:
diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk
new file mode 100644
index 0000000..6732748
--- /dev/null
+++ b/extensions/Module_extensions.mk
@@ -0,0 +1,32 @@
+# 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 Jan Holesovsky <kendy at suse.cz> (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.
+
+$(eval $(call gb_Module_Module,extensions))
+
+$(eval $(call gb_Module_add_check_targets,extensions,\
+ CppunitTest_extensions_test_update \
+))
+
+# vim:set shiftwidth=4 softtabstop=4 noexpandtab:
diff --git a/extensions/prj/build.lst b/extensions/prj/build.lst
index fd883a2..45bea6a 100644
--- a/extensions/prj/build.lst
+++ b/extensions/prj/build.lst
@@ -1,4 +1,4 @@
-ex extensions : officecfg TRANSLATIONS:translations DESKTOP:rdbmaker svx SANE:sane TWAIN:twain np_sdk offapi stoc ZLIB:zlib CURL:curl LIBXSLT:libxslt NULL
+ex extensions : officecfg TRANSLATIONS:translations DESKTOP:rdbmaker svx SANE:sane TWAIN:twain np_sdk offapi stoc ZLIB:zlib CURL:curl LIBXSLT:libxslt CPPUNIT:cppunit NULL
ex extensions usr1 - all ex_mkout NULL
ex extensions\inc nmake - all ex_inc NULL
diff --git a/extensions/qa/update/test_update.cxx b/extensions/qa/update/test_update.cxx
new file mode 100644
index 0000000..b1a02a0
--- /dev/null
+++ b/extensions/qa/update/test_update.cxx
@@ -0,0 +1,62 @@
+/*
+ * 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 Jan Holesovsky <kendy at suse.cz> (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 <sal/config.h>
+#include <sal/precppunit.hxx>
+
+#include <cppunit/TestAssert.h>
+#include <cppunit/TestFixture.h>
+#include <cppunit/extensions/HelperMacros.h>
+#include <cppunit/plugin/TestPlugIn.h>
+
+namespace testupdate {
+
+class test : public CppUnit::TestFixture
+{
+public:
+ void setUp() {}
+
+ void tearDown() {}
+
+protected:
+ // setup & test checkForUpdates() method
+ void testUpdateCheck()
+ {
+ //CPPUNIT_FAIL( "This has to be populated with the real test..." );
+ }
+
+ CPPUNIT_TEST_SUITE(test);
+ CPPUNIT_TEST(testUpdateCheck);
+ CPPUNIT_TEST_SUITE_END();
+};
+
+CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(testupdate::test, "update");
+} // namespace testupdate
+
+CPPUNIT_PLUGIN_IMPLEMENT();
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
More information about the Libreoffice-commits
mailing list