Stephan Herrmann | c656def | 2011-10-25 16:30:41 +0000 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
| 2 | |
| 3 | <!-- |
| 4 | Copyright (c) 2002, 2011 IBM Corporation and others. |
Stephan Herrmann | be6c0ea | 2010-04-01 21:59:30 +0000 | [diff] [blame] | 5 | All rights reserved. This program and the accompanying materials |
| 6 | are made available under the terms of the Eclipse Public License v1.0 |
| 7 | which accompanies this distribution, and is available at |
| 8 | http://www.eclipse.org/legal/epl-v10.html |
| 9 | |
| 10 | Contributors: |
| 11 | IBM Corporation - initial API and implementation |
| 12 | Technical University Berlin - adapted for Object Teams |
| 13 | --> |
| 14 | |
| 15 | <project name="testsuite" default="run" basedir="."> |
| 16 | <!-- The property ${eclipse-home} should be passed into this script --> |
| 17 | <!-- Set a meaningful default value for when it is not. --> |
| 18 | <property name="eclipse-home" value="${basedir}\..\.."/> |
| 19 | |
| 20 | <!-- sets the properties eclipse-home, and library-file --> |
| 21 | <property name="plugin-name" value="org.eclipse.jdt.core.tests.model"/> |
| 22 | <property name="library-file" |
| 23 | value="${eclipse-home}/plugins/${org.eclipse.test}/library.xml"/> |
| 24 | |
| 25 | <!-- This target holds all initialization code that needs to be done for --> |
| 26 | <!-- all tests that are to be run. Initialization for individual tests --> |
| 27 | <!-- should be done within the body of the suite target. --> |
| 28 | <target name="init"> |
| 29 | <tstamp/> |
| 30 | <delete> |
| 31 | <fileset dir="${eclipse-home}" includes="org*.xml"/> |
| 32 | </delete> |
| 33 | </target> |
| 34 | |
| 35 | <!-- This target defines the tests that need to be run. --> |
| 36 | <target name="suite"> |
| 37 | <!-- Java Model tests --> |
| 38 | <property name="jdt-model-folder" |
| 39 | value="${eclipse-home}/jdt_model_folder"/> |
| 40 | <delete dir="${jdt-model-folder}" quiet="true"/> |
| 41 | <ant target="core-test" antfile="${library-file}" dir="${eclipse-home}"> |
| 42 | <!-- Use a subdir 'data' so that the JCL jars are put in jdt-model-folder and are deleted at the end of the tests. --> |
| 43 | <property name="data-dir" value="${jdt-model-folder}/data"/> |
| 44 | <property name="vmargs" value="-XX:+HeapDumpOnOutOfMemoryError -DstoreMemory=jdtcoremodel_mem_trace,dir=${basedir}/../.."/> |
| 45 | <property name="plugin-name" value="${plugin-name}"/> |
| 46 | <property name="classname" |
| 47 | value="org.eclipse.jdt.core.tests.model.AllJavaModelTests"/> |
| 48 | </ant> |
| 49 | |
| 50 | <!-- DOM tests --> |
| 51 | <property name="jdt-dom-folder" |
| 52 | value="${eclipse-home}/jdt_dom_folder"/> |
| 53 | <delete dir="${jdt-dom-folder}" quiet="true"/> |
| 54 | <ant target="core-test" antfile="${library-file}" dir="${eclipse-home}"> |
| 55 | <!-- Use a subdir 'data' so that the JCL jars are put in jdt-model-folder and are deleted at the end of the tests. --> |
| 56 | <property name="data-dir" value="${jdt-dom-folder}/data"/> |
| 57 | <property name="plugin-name" value="${plugin-name}"/> |
| 58 | <property name="classname" |
| 59 | value="org.eclipse.jdt.core.tests.dom.RunAllTests"/> |
| 60 | </ant> |
| 61 | |
| 62 | <!-- Formatter tests --> |
| 63 | <property name="formatter-folder" |
| 64 | value="${eclipse-home}/formatter-folder"/> |
| 65 | <delete dir="${formatter-folder}" quiet="true"/> |
| 66 | <ant target="core-test" antfile="${library-file}" dir="${eclipse-home}"> |
| 67 | <property name="data-dir" value="${formatter-folder}"/> |
| 68 | <property name="plugin-name" value="${plugin-name}"/> |
| 69 | <property name="classname" |
| 70 | value="org.eclipse.jdt.core.tests.RunFormatterTests"/> |
| 71 | </ant> |
| 72 | </target> |
| 73 | |
| 74 | <!-- This target holds code to cleanup the testing environment after --> |
| 75 | <!-- after all of the tests have been run. You can use this target to --> |
| 76 | <!-- delete temporary files that have been created. --> |
| 77 | <target name="cleanup"> |
| 78 | </target> |
| 79 | |
| 80 | <!-- This target runs the test suite. Any actions that need to happen --> |
| 81 | <!-- after all the tests have been run should go here. --> |
| 82 | <target name="run" depends="init,suite,cleanup"> |
| 83 | <echo message="OTTest: done running ${plugin-name}"/> |
| 84 | <!-- ObjectTeams: per-plugin collect not needed. |
| 85 | <ant target="collect" antfile="${library-file}" dir="${eclipse-home}"> |
| 86 | <property name="includes" value="org*.xml"/> |
| 87 | <property name="output-file" value="${plugin-name}.xml"/> |
| 88 | </ant> |
| 89 | --> |
| 90 | </target> |
| 91 | |
| 92 | <!-- This target runs the performance test suites. --> |
| 93 | <target name="performance"> |
| 94 | </target> |
| 95 | |
| 96 | </project> |