|
@@ -55,6 +55,7 @@
|
|
|
<property name="test.log.dir" value="${test.build.dir}/logs" />
|
|
|
<property name="test.data.dir" value="${test.build.dir}/data" />
|
|
|
<property name="test.data.upgrade.dir" value="${test.data.dir}/upgrade" />
|
|
|
+ <property name="test.cppunit.dir" value="${test.build.dir}/test-cppunit"/>
|
|
|
<property name="test.tmp.dir" value="${test.build.dir}/tmp" />
|
|
|
<property name="test.output" value="no" />
|
|
|
<property name="test.timeout" value="900000" />
|
|
@@ -572,7 +573,43 @@
|
|
|
<fail if="tests.failed">Tests failed!</fail>
|
|
|
</target>
|
|
|
|
|
|
+ <target name="create-cppunit-configure" depends="init" if="cppunit">
|
|
|
+ <exec executable="autoreconf" dir="${c.src.dir}" searchpath="yes"
|
|
|
+ failonerror="yes">
|
|
|
+ <arg value="-if"/>
|
|
|
+ </exec>
|
|
|
+ </target>
|
|
|
|
|
|
+ <target name="check-cppunit-makefile" depends="init" >
|
|
|
+ <condition property="need.cppunit.makefile">
|
|
|
+ <not> <available file="${test.cppunit.dir}/Makefile"/> </not>
|
|
|
+ </condition>
|
|
|
+ </target>
|
|
|
+
|
|
|
+ <target name="create-cppunit-makefile" depends="check-cppunit-makefile"
|
|
|
+ if="need.cppunit.makefile">
|
|
|
+ <mkdir dir="${test.cppunit.dir}"/>
|
|
|
+ <exec executable="${c.src.dir}/configure" dir="${test.cppunit.dir}"
|
|
|
+ failonerror="yes">
|
|
|
+ <env key="base_dir" value="${basedir}"/>
|
|
|
+ <env key="CALLER" value="ANT"/>
|
|
|
+ <arg value="--prefix=${test.cppunit.dir}"/>
|
|
|
+ </exec>
|
|
|
+ </target>
|
|
|
+
|
|
|
+ <target name="test-cppunit" depends="compile_jute, jar, create-cppunit-makefile" if="cppunit"
|
|
|
+ description="to run cppunit test cases">
|
|
|
+ <property name="fuser.bin" value="/sbin"/>
|
|
|
+ <property name="lib.cppunit" value="/usr/local/lib"/>
|
|
|
+ <exec dir="${test.cppunit.dir}" executable="make">
|
|
|
+ <env key="LD_LIBRARY_PATH" value="${lib.cppunit}"/>
|
|
|
+ <env key="PATH" path="${env.PATH};${c.src.dir};${fuser.bin};"/>
|
|
|
+ <env key="CALLER" value="ANT"/>
|
|
|
+ <env key="base_dir" value="${basedir}"/>
|
|
|
+ <arg line="clean run-check"/>
|
|
|
+ </exec>
|
|
|
+ </target>
|
|
|
+
|
|
|
<target name="test-unit-category">
|
|
|
<property name="test.category" value="Unit"/>
|
|
|
</target>
|