Ant gputest target now also runs Java+C GPU tests.

This commit is contained in:
Pedro Martinez Mediano 2017-05-22 15:06:34 +10:00
parent 9b455f7ef4
commit 74e65b624c
1 changed files with 24 additions and 3 deletions

View File

@ -99,7 +99,6 @@
<!-- If applicable, run also GPU tests -->
<antcall target="gputest" if:true="${enablegpu}"/>
</target>
<!-- Make javadocs, excluding the classes we've derived from Apache Commons Math -->
@ -199,9 +198,9 @@
</target>
<!-- Test GPU code -->
<target name="gputest" depends="gpu" description="compile and run C unit tests for GPU code">
<target name="gputest" depends="gpu, compile" description="compile and run C unit tests for GPU code">
<!-- Compile the GPU unit tests -->
<!-- Compile and run the C-only GPU unit tests -->
<exec executable="make" dir="${src}/infodynamics/measures/continuous/kraskov/cuda/">
<arg value="test"/>
</exec>
@ -212,6 +211,28 @@
<exec executable="./unittest" dir="${unittestsbin}/infodynamics/measures/continuous/kraskov/cuda/"/>
<!-- Compile and run the Java+C GPU tests -->
<javac destdir="${unittestsbin}" includeAntRuntime="true" debug="true">
<src path="${unittestssrc}"/>
<classpath refid="project.classpath"/>
<classpath refid="apache-classpath"/>
</javac>
<junit printsummary="yes" showoutput="yes" fork="true" forkmode="once" haltonfailure="yes" haltonerror="yes" includeantruntime="true">
<classpath>
<path refid="project.classpath"/>
<pathelement path="${unittestsbin}"/>
<pathelement location="${basedir}/clover.jar"/>
</classpath>
<formatter type="plain"/>
<batchtest todir="${reports.tests}"> <!-- Writes full reports with stdout and stderr to ${reports.tests} -->
<fileset dir="${unittestsbin}">
<include name="**/GPUMutualInfoTester.class"/>
<include name="**/GPUPerformanceTester.class"/>
</fileset>
</batchtest>
</junit>
</target>
<!-- Developer build - creates readme and version files -->