ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Lemieux (QC/EMC)" <David.Lemi...@ericsson.com>
Subject Junit optional taskdef
Date Thu, 06 Nov 2003 21:25:15 GMT
Hi,

I'm trying to use the junit optional task.
If I put the junit.jar in the ANT_HOME/lib everything work fine.

The problem is that I have to use the build script in many different environment(pc,unix,IDE,...)
using different installation of ant and I can't put the junit.jar everywhere. I'd like to
do something like this:

	<taskdef name="junit" classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask">
	  <classpath>
    		<fileset dir="${dirundermyproject}/ant/">
    			<include name="optional.jar"/>
    		</fileset>
    		<fileset dir="${dirundermyproject}/junit/3.8.1/">
    			<include name="junit.jar"/>
    		</fileset>
	  </classpath>
	</taskdef>

that would activate the junit task independently of the environment.

Or, is there a way to modify the classpath in which ant is started in the build file? 
Then I could add the jar from under my project.

I don't want to maintain the different classpath or invocation line of the ant script to reflect
any additionnal use of optinnal task.

Thanks

David

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


Mime
View raw message