> Because JUnit is not on the system classpath. You must path
> classpath="where.junit.is" to your taskdef.

Fair enough...

So I change my taskdef thusly:


   <goal name="funk">
       <taskdef name="junit"
                classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask"
                classpathref="maven.dependency.classpath"
                />
   </goal>

Where my project.xml contains:

    <dependency>
      <id>junit</id>
      <version>3.7</version>
      <properties>
        <war.bundle.jar></war.bundle.jar>
      </properties>
    </dependency>

and just to be stupid:

    <dependency>
      <id>ant:ant-optional</id>
      <version>1.5</version>
    </dependency>

and I get the same behavior.

>
> Aslak
>
>> -----Original Message-----
>> From: James CE Johnson [mailto:[EMAIL PROTECTED]]
>> Sent: 21. november 2002 18:40
>> To: [EMAIL PROTECTED]
>> Subject: Can't find JUnitTask?
>>
>>
>> Why would this:
>>
>>   <goal name="funk">
>>       <taskdef name="junit"
>>
>> classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTask"
>>                />
>>   </goal>
>>
>> Result in this:
>>
>> funk:
>>
>> [ERROR] BUILD FAILED
>> [ERROR] taskdef class
>> org.apache.tools.ant.taskdefs.optional.junit.JUnitTask cannot be found
>>
>> I'm using the 11/18 CVS version of Maven.
>>
>> Thanks,
>> J
>>
>>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to