ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From k...@apache.org
Subject svn commit: r540538 - in /ant/sandbox/antlibs/debian/trunk/src/tests/antunit: build-test.xml install-test.xml
Date Tue, 22 May 2007 11:45:21 GMT
Author: kevj
Date: Tue May 22 04:45:20 2007
New Revision: 540538

URL: http://svn.apache.org/viewvc?view=rev&rev=540538
Log:
-skeleton antunit tests

Added:
    ant/sandbox/antlibs/debian/trunk/src/tests/antunit/build-test.xml
    ant/sandbox/antlibs/debian/trunk/src/tests/antunit/install-test.xml

Added: ant/sandbox/antlibs/debian/trunk/src/tests/antunit/build-test.xml
URL: http://svn.apache.org/viewvc/ant/sandbox/antlibs/debian/trunk/src/tests/antunit/build-test.xml?view=auto&rev=540538
==============================================================================
--- ant/sandbox/antlibs/debian/trunk/src/tests/antunit/build-test.xml (added)
+++ ant/sandbox/antlibs/debian/trunk/src/tests/antunit/build-test.xml Tue May 22 04:45:20
2007
@@ -0,0 +1,45 @@
+<?xml version="1.0"?>
+<project default="all" basedir="../../../.."
+  xmlns:au="antlib:org.apache.ant.antunit"
+  xmlns:deb="antlib:org.apache.ant.debian">
+
+  <property name="ant.src.dir" value="${basedir}/ant-core-trunk"/>
+  <property name="package" value="${ant.src.dir}/ant_1.7.1_all.deb"/>
+  <property name="controlfile" value="${ant.src.dir}/dist/DEBIAN/control"/>
+
+  <target name="tearDown">
+    <delete file="${controlfile}"/>
+    <delete file="${package}"/>
+  	<delete dir="${ant.src.dir}/dist/DEBIAN"/>
+  </target>
+
+  <target name="setUp">
+  	<mkdir dir="${ant.src.dir}/dist/DEBIAN"/>
+  	<au:assertFileExists file="${ant.src.dir}/dist/DEBIAN"/>
+    <au:assertFileDoesntExist file="${controlfile}"/>
+  	<deb:control file="${controlfile}" 
+  	  package="ant" version="1.7.1alpha" maintainer="kevj@apache.org"
+  	  essential="no" priority="optional" section="Development" architecture="all">
+  	  <dependency name="java-gjc-compat | java-virtual-machine"/>
+  	  <dependency name="java-gjc-compat | java1-runtime | java2-runtime"/>
+  	  <dependency name="libxerces2-java"/>
+  	  <recommends name="ant-optional"/>
+  	  <recommends name="jike | java-compiler"/>
+  	  <description>Java based build tool like make</description>
+  	</deb:control>
+    <au:assertFileExists file="${controlfile}"/>
+  </target>
+
+  <target name="test-build">
+    <au:assertFileDoesntExist file="${package}"/>
+    <deb:dpkg packageName="${package}" dir="${ant.src.dir}/dist"/>
+    <au:assertFileExists file="${package}"/>
+  </target>
+
+  <target name="all">
+    <au:antunit>
+      <fileset file="${ant.file}"/>
+      <au:plainlistener/>
+    </au:antunit>
+  </target>
+</project>
\ No newline at end of file

Added: ant/sandbox/antlibs/debian/trunk/src/tests/antunit/install-test.xml
URL: http://svn.apache.org/viewvc/ant/sandbox/antlibs/debian/trunk/src/tests/antunit/install-test.xml?view=auto&rev=540538
==============================================================================
--- ant/sandbox/antlibs/debian/trunk/src/tests/antunit/install-test.xml (added)
+++ ant/sandbox/antlibs/debian/trunk/src/tests/antunit/install-test.xml Tue May 22 04:45:20
2007
@@ -0,0 +1,20 @@
+<?xml version="1.0"?>
+<project default="all" 
+  xmlns:au="antlib:org.apache.ant.antunit"
+  xmlns:deb="antlib:org.apache.ant.debian">
+
+  <property name="package" value="cf"/>
+  <property name="installed" value=""/>
+
+  <target name="test-install">
+    <deb:install packagename="${package}"/>
+    <au:assertFileExists file="${installed}"/>
+  </target>
+  
+  <target name="all">
+    <au:antunit>
+      <fileset file="${ant.file}"/>
+      <au:plainlistener/>
+    </au:antunit>
+  </target>
+</project>
\ No newline at end of file



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message