ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jacob Kjome <>
Subject Ant 1.7.0 can't find Junit in ${user.home}/.ant/lib
Date Wed, 07 Feb 2007 02:51:14 GMT

Maybe this is a known issue, but it appears that Junit.jar must be in 
${ant.home}/lib in order to be discovered, at least by the 
<available> task using Ant-1.7.0.  In Ant-1.6.5, Junit is found just 
fine in ${user.home}/.ant/lib, but not in Ant-1.7.0.  For instance...

   <target name="-check.junit.exists">
     <available classname="junit.framework.TestCase"
                property="junit.exists" value="true"/>

   <target name="-check.junit" depends="-check.junit.exists" 
     <echo>JUnit is not currently available to the build environment. 
Because of this, all targets that require JUnit will be skipped. To 
enable these targets, place a copy of JUnit (get latest version at in ANT_HOME/lib.</echo>

   <target name="build.something" depends="-check.junit" if="junit.exists">

With junit.jar in ${user.home}/.ant/lib and using Ant-1.7.0, I always 
get the <echo> message.  If I move junit.jar to ${ant.home}/lib, I 
don't get the <echo> message.  Ant-1.6.5 doesn't care where I put 
it.  It finds junit.jar in either location.

Is this a known issue?  Has it already been fixed for Ant-1.7.1?


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

View raw message