Simplified to does not contain the friend API, instead the SPI is directly define by the API
1 <?xml version="1.0" encoding="UTF-8"?>
2 <project name="Build Script" default="test" basedir=".">
7 <target name="build" depends="-libraries">
8 <antcall target="-build-one">
9 <param name="version" value="new-api"/>
11 <antcall target="-build-one">
12 <param name="version" value="bridge"/>
13 <param name="cp" value="build/new-api/classes"/>
16 <antcall target="-build-one">
17 <param name="version" value="test"/>
18 <param name="cp" value="build/new-api/classes:${junit.jar}"/>
22 <target name="test" depends="build">
23 <echo level="info" message="Running the tests with bridge enabled. This should succeeds."/>
24 <antcall target="-run-one">
25 <param name="test.cp" value="build/new-api/classes:build/bridge/classes"/>
27 <echo level="info" message="Running the tests without bridge module. This should fail."/>
28 <antcall target="-run-one">
29 <param name="test.cp" value="build/new-api/classes"/>
33 <!-- support methods -->
35 <target name="-libraries">
38 <property name="junit.jar" location="../libs/dist/junit-4.4.jar"/>
41 <target name="-run-one">
42 <mkdir dir="build/testresults"/>
43 <junit dir="build/test/classes" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
44 <batchtest todir="build/testresults">
45 <fileset dir="build/test/classes">
46 <filename name="**/*Test.class"/>
50 <path path="${test.cp}"/>
51 <path location="build/test/classes"/>
52 <path location="${junit.jar}"/>
54 <formatter type="brief" usefile="false"/>
55 <formatter type="xml"/>
59 <target name="-build-one">
60 <fail message="You need to specify version number" unless="version"/>
62 <mkdir dir="build/${version}/classes"/>
63 <property name="cp" value=""/>
65 srcdir="src-${version}"
66 destdir="build/${version}/classes"
67 source="1.5" target="1.5"
70 <copy todir="build/${version}/classes">
71 <fileset dir="src-${version}">
72 <exclude name="**/*.java"/>