You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by "Bryan P. Glennon" <br...@bpgc.com> on 2001/12/10 23:18:29 UTC

JUnit optional task

When I try to use the Junit task (with ant 1.4.1, Junit 3.7 and
jdk1.2.2) I get the following error:

Could not create task of type: junit. Common solutions are to use
taskdef to declare your task, or, if this is an optional task, to put
the optional.jar in the lib directory of your ant installation
(ANT_HOME).

Well, optional.jar is in the ANT_HOME/lib dir (as is
jakarta-ant-1.4.1-optional.jar.) Actually, optional.jar is just a copy
of jakarta-ant-1.4.1-optional.jar.

So, what am I doing wrong?

Thanks,
Bryan
--
Bryan Glennon (mailto:bryan@bpgc.com)
BPG Consulting, Inc. (http://www.bpgc.com)
Tech Question? (mailto:techQuestion@bpgc.com)

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: JUnit optional task

Posted by Jesse Stockall <je...@cryptocard.com>.
On Mon, 2001-12-10 at 17:18, Bryan P. Glennon wrote:
> When I try to use the Junit task (with ant 1.4.1, Junit 3.7 and
.
> 
> So, what am I doing wrong?
> 
>

The Ant manual gives a listing of the jars required to run certain
optional tasks

Have a look at
http://jakarta.apache.org/ant/manual/install.html#librarydependencies

In short you need to put junit.jar in $ANT_HOME/lib
 
-- 
 Jesse Stockall			|	Tel: 1+ 613.599.2441 ext. 243
 CRYPTOCard Corporation		|	Fax: 1+ 613.599.2442	 	
 Suite 304, 300 March Rd.	|	email: jesse@cryptocard.com
 Ottawa, ON, Canada K2K 2E2	|	web: www.cryptocard.com 
---------------------------------------------------------------------


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: JUnit optional task

Posted by Jill Stephenson <ji...@suncorpmetway.com.au>.
Add JUNIT_HOME/junit.jar to your classpath before
invoking ant.

--
Jill

----- Original Message ----- 
From: "Bryan P. Glennon" <br...@bpgc.com>
To: <an...@jakarta.apache.org>
Sent: Tuesday, December 11, 2001 8:18 AM
Subject: JUnit optional task


When I try to use the Junit task (with ant 1.4.1, Junit 3.7 and
jdk1.2.2) I get the following error:

Could not create task of type: junit. Common solutions are to use
taskdef to declare your task, or, if this is an optional task, to put
the optional.jar in the lib directory of your ant installation
(ANT_HOME).

Well, optional.jar is in the ANT_HOME/lib dir (as is
jakarta-ant-1.4.1-optional.jar.) Actually, optional.jar is just a copy
of jakarta-ant-1.4.1-optional.jar.

So, what am I doing wrong?

Thanks,
Bryan
--
Bryan Glennon (mailto:bryan@bpgc.com)
BPG Consulting, Inc. (http://www.bpgc.com)
Tech Question? (mailto:techQuestion@bpgc.com)

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>



-----------------------------------------------------------------------------------

The contents of this message are the views of the Author and do not necessarily reflect the views of SUNCORP METWAY LTD  ABN 66 010 831 722. 

The content of this e-mail, including attachments is a confidential communication between the Suncorp Metway Group and the intended addressee. Any unauthorised use of the contents is expressly prohibited. If you have received this e-mail in error please contact the sender immediately and then delete the message and any attachment(s).

http://www.suncorpmetway.com.au


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: JUnit optional task

Posted by William Ferguson <wi...@versata.com>.
You can either

1) put junit.jar in %ANT_HOME%\lib
2) add it to the classpath when invoking Ant
3) leave jnuint.jar where it is and move Ant's optional.jar out of
%ANT_HOME%\lib and specify the path to both junit.jar and optional.jar in
the taskdef for the Junit task.


William

> -----Original Message-----
> From: Bryan P. Glennon [mailto:bryan@bpgc.com]
> Sent: Tuesday, 11 December 2001 9:18
> To: ant-user@jakarta.apache.org
> Subject: JUnit optional task
>
>
> When I try to use the Junit task (with ant 1.4.1, Junit 3.7 and
> jdk1.2.2) I get the following error:
>
> Could not create task of type: junit. Common solutions are to use
> taskdef to declare your task, or, if this is an optional task, to put
> the optional.jar in the lib directory of your ant installation
> (ANT_HOME).
>
> Well, optional.jar is in the ANT_HOME/lib dir (as is
> jakarta-ant-1.4.1-optional.jar.) Actually, optional.jar is just a copy
> of jakarta-ant-1.4.1-optional.jar.
>
> So, what am I doing wrong?
>
> Thanks,
> Bryan
> --
> Bryan Glennon (mailto:bryan@bpgc.com)
> BPG Consulting, Inc. (http://www.bpgc.com)
> Tech Question? (mailto:techQuestion@bpgc.com)
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>