aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2010-11-07 07:27:16 +0100
committerSven Gothel <[email protected]>2010-11-07 07:27:16 +0100
commit92379944aa91a78dbebf7fe6537a43fb64f71f9a (patch)
tree452ab4f0a16ba4dca623b493358f8a4cec21ac86
parentc0f7019bf8f68293aec944ff0faee3977674b990 (diff)
Tests: Enable all tests ; Remove 'test' target -> 'junit.run' ; Fix junit chained tests;
Enable all tests - Remove 'test' target -> 'junit.run' - calls build.xml tests first, then - calls build-junit.xml tests - build.xml unit tests were disabled, enable them via junit.run
-rw-r--r--make/build-junit.xml9
-rwxr-xr-xmake/build.xml75
2 files changed, 42 insertions, 42 deletions
diff --git a/make/build-junit.xml b/make/build-junit.xml
index 1e41e3e..72428b4 100644
--- a/make/build-junit.xml
+++ b/make/build-junit.xml
@@ -22,9 +22,9 @@
<property name="make" value="." />
<property name="test.base.dir" value="${gluegen.root}/src/junit" />
- <property name="test.junit.rel" value="com/jogamp" />
+ <property name="test.junit.rel" value="com/jogamp/gluegen/test/junit" />
<property name="test.junit.dir" value="${test.base.dir}/${test.junit.rel}" />
- <property name="test.junit.generation.rel" value="${test.junit.rel}/gluegen/test/junit/generation" />
+ <property name="test.junit.generation.rel" value="${test.junit.rel}/generation" />
<property name="test.junit.generation.dir" value="${test.base.dir}/${test.junit.generation.rel}" />
<property name="test.dir" value="${gluegen.root}/${rootrel.build}/test"/>
@@ -186,11 +186,6 @@
</target>
<target name="junit.run" depends="init,gluegen.cpptasks.detect.os">
- <mkdir dir="${results}"/>
- <delete quiet="true">
- <fileset dir="${results}" includes="**"/>
- </delete>
-
<!-- Use absolute path -->
<property name="gluegen.lib.abs" location="${gluegen.lib}" />
<property name="build_t.lib.abs" location="${build_t.lib}" />
diff --git a/make/build.xml b/make/build.xml
index b6b2e64..0017a3e 100755
--- a/make/build.xml
+++ b/make/build.xml
@@ -86,6 +86,9 @@
<property name="gluegen.build" value="${src.generated.java}/com/jogamp/gluegen" />
<property name="generated.java.from.c.grammar" value="${gluegen.build}/cgram" />
<property name="generated.java.from.j.grammar" value="${gluegen.build}/jgram" />
+
+ <property name="tools.jar" value="${java.home}/../lib/tools.jar"/>
+
</target>
<!--
@@ -661,48 +664,50 @@
</delete>
</target>
- <target name="test" depends="init, gluegen.cpptasks.detect.os">
- <mkdir dir="${build}/test/build/classes"/>
- <mkdir dir="${build}/test/results"/>
-
- <property name="tools.jar" value="${java.home}/../lib/tools.jar"/>
-
- <javac destdir="${build}/test/build/classes" srcdir="${gluegen.root}/test/junit" source="1.5" failonerror="false"
- debug="true" debuglevel="lines,vars,source" includeAntRuntime="false">
- <classpath path="${junit.jar}:${build}/classes:${build}/test/gensrc/java:${tools.jar}:${ant.core.lib}"/>
- </javac>
-
- <junit forkmode="once" showoutput="true" fork="true" includeAntRuntime="true">
- <env key="${system.env.library.path}" path="${gluegen.lib.dir}${path.separator}${build}/test/build/natives"/>
- <jvmarg value="-Djava.library.path=${gluegen.lib.dir}${path.separator}${build}/test/build/natives"/>
- <jvmarg value="-Drootrel.build=${rootrel.build}"/>
- <jvmarg value="-Dos.arch=${os.arch}"/>
- <jvmarg value="-Dgluegen.user.compiler.file=${gluegen.user.compiler.file}"/>
- <batchtest todir="${build}/test/results">
- <fileset dir="${build}/test/build/classes">
- <include name="com/jogamp/gluegen/**Test*"/>
- <include name="com/jogamp/common/nio/**Test*"/>
- <include name="com/jogamp/common/util/**Test*"/>
- <include name="com/jogamp/common/util/locks/**Test*"/>
- </fileset>
- <formatter usefile="false" type="plain"/>
- <formatter usefile="true" type="xml"/>
- </batchtest>
- <classpath>
- <path path="${build}/test/build/classes:${build}/test/gensrc/java:${build}/classes:${antlr.jar}:${junit.jar}:${tools.jar}:${ant.core.lib}"/>
- </classpath>
- </junit>
- </target>
-
<target name="tag.build" depends="init">
<echo message='gluegen.build.number=${gluegen.build.number}${line.separator}' file="${build}/artifact.properties"/>
</target>
- <target name="junit.compile">
+ <target name="junit.compile" depends="init, gluegen.cpptasks.detect.os">
+ <mkdir dir="${build}/test/build/classes"/>
+
+ <javac destdir="${build}/test/build/classes" srcdir="${gluegen.root}/test/junit" source="1.5" failonerror="false"
+ debug="true" debuglevel="lines,vars,source" includeAntRuntime="false"
+ excludes="com/jogamp/gluegen/StructValidator.java">
+ <classpath path="${junit.jar}:${build}/classes:${build}/test/gensrc/java:${tools.jar}:${ant.core.lib}"/>
+ </javac>
+
<ant antfile="build-junit.xml" target="junit.compile"/>
</target>
- <target name="junit.run">
+ <target name="junit.run" depends="junit.compile">
+ <mkdir dir="${build}/test/results"/>
+ <delete quiet="true">
+ <fileset dir="${build}/test/results" includes="**"/>
+ </delete>
+
+ <junit forkmode="once" showoutput="true" fork="true" includeAntRuntime="true">
+ <env key="${system.env.library.path}" path="${gluegen.lib.dir}${path.separator}${build}/test/build/natives"/>
+ <jvmarg value="-Djava.library.path=${gluegen.lib.dir}${path.separator}${build}/test/build/natives"/>
+ <jvmarg value="-Drootrel.build=${rootrel.build}"/>
+ <jvmarg value="-Dos.arch=${os.arch}"/>
+ <jvmarg value="-Dgluegen.user.compiler.file=${gluegen.user.compiler.file}"/>
+ <batchtest todir="${build}/test/results">
+ <fileset dir="${build}/test/build/classes">
+ <include name="com/jogamp/gluegen/**Test*"/>
+ <include name="com/jogamp/common/nio/**Test*"/>
+ <include name="com/jogamp/common/util/**Test*"/>
+ <include name="com/jogamp/common/util/locks/**Test*"/>
+ <exclude name="**/*$$*"/>
+ </fileset>
+ <formatter usefile="false" type="plain"/>
+ <formatter usefile="true" type="xml"/>
+ </batchtest>
+ <classpath>
+ <path path="${build}/test/build/classes:${build}/test/gensrc/java:${build}/classes:${antlr.jar}:${junit.jar}:${tools.jar}:${ant.core.lib}"/>
+ </classpath>
+ </junit>
+
<ant antfile="build-junit.xml" target="junit.run"/>
</target>