ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Lévy-Lambert <>
Subject AW: Junit optional taskdef
Date Thu, 06 Nov 2003 21:57:24 GMT
See this URL :
I guess the best solution would be to go straight to ant 1.6 (you can
download the beta2).
Then you can use the second solution which is to move ant-junit.jar out of
the classpath, that is to say out of $ANT_HOME/lib if you are running ant
from the command line.
Then you can taskdef junit using ant-junit.jar and junit.jar, as you

There is no way in the build file to change the classpath in which ant is



-----Urspr√ľngliche Nachricht-----
Von: David Lemieux (QC/EMC) []
Gesendet: Donnerstag, 6. November 2003 22:25
An: Ant Users List (E-mail)
Betreff: Junit optional taskdef


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"
    		<fileset dir="${dirundermyproject}/ant/">
    			<include name="optional.jar"/>
    		<fileset dir="${dirundermyproject}/junit/3.8.1/">
    			<include name="junit.jar"/>

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.



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message