blob: 053cb25de188d930363d7f4969947162d9650bd6 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<project name="testsuite" default="run" basedir=".">
<!-- The property ${eclipse-home} should be passed into this script -->
<!-- Set a meaningful default value for when it is not. -->
<property name="eclipse-home" value="${LOCAL_M2_REPO}/eclipse/eclipse"/>
<!-- sets the properties eclipse-home, and library-file -->
<property name="plugin-name" value="org.apache.openejb.helper.annotation.test"/>
<property name="library-file"
value="${eclipse-home}/plugins/org.eclipse.test_3.2.0/library.xml"/>
<target name="win32">
<property name="os" value="win32"/>
<property name="ws" value="win32"/>
<property name="arch" value="x86"/>
<ant target="run" antfile="test.xml"/>
</target>
<target name="linux_x86_64">
<property name="os" value="linux"/>
<property name="ws" value="gtk"/>
<property name="arch" value="x86_64"/>
<ant target="run" antfile="test.xml"/>
</target>
<target name="linux">
<property name="os" value="linux"/>
<property name="ws" value="gtk"/>
<property name="arch" value="x86"/>
<ant target="run" antfile="test.xml"/>
</target>
<target name="macos">
<property name="os" value="macosx"/>
<property name="ws" value="carbon"/>
<property name="arch" value="x86"/>
<ant target="run" antfile="test.xml"/>
</target>
<!-- This target holds all initialization code that needs to be done for -->
<!-- all tests that are to be run. Initialization for individual tests -->
<!-- should be done within the body of the suite target. -->
<target name="init">
<tstamp/>
<delete>
<fileset dir="${eclipse-home}" includes="org*.xml"/>
</delete>
</target>
<!-- This target defines the tests that need to be run. -->
<target name="suite">
<property name="test-folder"
value="${eclipse-home}/test_folder"/>
<delete dir="${test-folder}" quiet="true"/>
<ant target="ui-test" antfile="${library-file}" dir="${eclipse-home}">
<property name="data-dir" value="${test-folder}"/>
<property name="plugin-name" value="${plugin-name}"/>
<property name="classname"
value="org.apache.openejb.helper.annotation.tests.AllTests"/>
</ant>
</target>
<!-- This target holds code to cleanup the testing environment after -->
<!-- after all of the tests have been run. You can use this target to -->
<!-- delete temporary files that have been created. -->
<target name="cleanup">
</target>
<!-- This target runs the test suite. Any actions that need to happen -->
<!-- after all the tests have been run should go here. -->
<target name="run" depends="init,suite,cleanup">
<echo message="Running tests..."/>
<ant target="collect" antfile="${library-file}" dir="${eclipse-home}">
<property name="includes" value="org*.xml"/>
<property name="output-file" value="${plugin-name}.xml"/>
</ant>
</target>
</project>