summaryrefslogtreecommitdiff
path: root/sw/qa/unoapi
diff options
context:
space:
mode:
authorsb <sb@openoffice.org>2010-02-12 17:36:13 +0100
committersb <sb@openoffice.org>2010-02-12 17:36:13 +0100
commit5a43d0dca53727209d19369048ac2ee514024776 (patch)
tree6e04a099dd1e589a0e02e153302463036f362825 /sw/qa/unoapi
parente519e5770b8744eeea04c78bffcf754a7cf87a7b (diff)
sb118: moved test OOo installation stuff to new solenv/inc/installationtest.mk (makefile parts) and new test module (C++ and, new, Java unit test parts); adapted sw/qa/unoapi to new (Java) test framework
Diffstat (limited to 'sw/qa/unoapi')
-rw-r--r--sw/qa/unoapi/Test.java51
-rw-r--r--sw/qa/unoapi/makefile.mk35
2 files changed, 70 insertions, 16 deletions
diff --git a/sw/qa/unoapi/Test.java b/sw/qa/unoapi/Test.java
new file mode 100644
index 000000000000..e0311cc069bb
--- /dev/null
+++ b/sw/qa/unoapi/Test.java
@@ -0,0 +1,51 @@
+/*************************************************************************
+* 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.
+************************************************************************/
+
+package org.openoffice.sw.qa.unoapi;
+
+import org.openoffice.Runner;
+import org.openoffice.test.OfficeConnection;
+import static org.junit.Assert.*;
+
+public final class Test {
+ @org.junit.Before public void setUp() throws Exception {
+ connection.setUp();
+ }
+
+ @org.junit.After public void tearDown()
+ throws InterruptedException, com.sun.star.uno.Exception
+ {
+ connection.tearDown();
+ }
+
+ @org.junit.Test public void test() {
+ assertTrue(
+ Runner.run(
+ "-sce", "sw.sce", "-xcl", "knownissues.xcl", "-tdoc",
+ "testdocuments", "-cs", connection.getDescription()));
+ }
+
+ private final OfficeConnection connection = new OfficeConnection();
+}
diff --git a/sw/qa/unoapi/makefile.mk b/sw/qa/unoapi/makefile.mk
index 7e01e4819dab..53761c22d42d 100644
--- a/sw/qa/unoapi/makefile.mk
+++ b/sw/qa/unoapi/makefile.mk
@@ -1,14 +1,9 @@
#*************************************************************************
-#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2008 by Sun Microsystems, Inc.
-#
-# OpenOffice.org - a multi-platform office productivity suite
#
-# $RCSfile: makefile.mk,v $
+# Copyright 2000, 2010 Oracle and/or its affiliates.
#
-# $Revision: 1.7 $
+# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
@@ -26,18 +21,26 @@
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..$/..
+#***********************************************************************/
-PRJNAME=sw
-TARGET=qa_unoapi
+.IF "$(OOO_SUBSEQUENT_TESTS)" == ""
+nothing .PHONY:
+.ELSE
-.INCLUDE: settings.mk
+PRJ = ../..
+PRJNAME = sw
+TARGET = qa_unoapi
+PACKAGE = org/openoffice/sw/qa/unoapi
+JAVATESTFILES = Test.java
+JAVAFILES = $(JAVATESTFILES)
+JARFILES = OOoRunner.jar ridl.jar test.jar
+EXTRAJARFILES = $(OOO_JUNIT_JAR)
+
+.INCLUDE: settings.mk
.INCLUDE: target.mk
+.INCLUDE: installationtest.mk
-ALLTAR : UNOAPI_TEST
+ALLTAR : javatest
-UNOAPI_TEST:
- +$(SOLARENV)$/bin$/checkapi -sce sw.sce -xcl knownissues.xcl -tdoc $(PWD)$/testdocuments
+.END