ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "William E. Kempf" <weke...@cox.net>
Subject Re: JUnit and bootclasspath
Date Sat, 18 Jan 2003 05:58:54 GMT

Stefan Bodewig said:
> On Fri, 17 Jan 2003, William E. Kempf <wekempf@cox.net> wrote:
>
>> OK, I don't mind specififying the "bootclasspath" if that will help
>> here, but how do I go about doing this in an Ant script using a
>> classpath variable?
>
> First of all, if you are not forking <junit>, it has to be on the
> bootclasspath of the VM running Ant.  This can be done by specifying
> java's -bootclasspath option in the ANT_OPTS environment variable.
>
> If you are forking <junit>, you could specify the -bootclasspath
> option as <jvmarg>.  Adding <bootclasspath> to side <classpath> to
the
> JUnit task could be a very valid enhancement request.

Part of my question is how to use a classpathref here.  This is the
current code:

<junit printsummary="no"
       errorProperty="test.failed"
       failureProperty="test.failed"
       fork="yes">
	<classpath refid="mylib.classpath"/>
	<sysproperty key="docs.dir" value="${junit.data.dir}" />
	<sysproperty key="index.dir" value="${junit.data.dir}/index" />
	<formatter type="xml" />
	<formatter type="brief" usefile="false" />
	<test name="${testcase}" if="testcase" />
	<batchtest todir="${junit.data.dir}" unless="testcase">
		<fileset dir="${build.dir}" includes="**/*Test.class" />
	</batchtest>
</junit>

How do I reuse the "mylib.classpath" here?

<junit printsummary="no"
       errorProperty="test.failed"
       failureProperty="test.failed"
       fork="yes">
	<classpath refid="mylib.classpath"/>
	<jvmarg value="-bootclasspath=...

William E. Kempf
wekempf@cox.net



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


Mime
View raw message