ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geng, Bo (Bob)" <bg...@lucent.com>
Subject Could not create task of type: junitreport!?
Date Wed, 13 Mar 2002 05:16:38 GMT
I had put the optional.jar int the lib directory of my ANT_HOME. But when I
tried to use the junitreport task, there was an error:

helloWorld\build.xml:93: Could not create task of type: junitreport. 
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).

The following is part of build.xml for unit test:

    <target name="test" depends="init" description="Run unit tests">
        <delete dir="${junit.results}"/>
        <mkdir dir="${junit.results}"/>
        <echo message="Running unit tests..."/>
        <junit fork="yes" haltonfailure="yes">
            <classpath>
                <path refid="classpath"/>
                <pathelement location="${build.dir}"/>
            </classpath>
            <formatter type="brief" usefile="false"/>
            <formatter type="xml"/>
            <batchtest todir="${junit.results}">
                <fileset dir="${build.dir}" includes="**/*Test.class"/>
            </batchtest>
        </junit>
	<junitreport todir="${junit.results}">
  		<fileset dir="${junit.results}">
    			<include name="TEST-*.xml"/>
  		</fileset>
  		<report format="frames" todir="${junit.results}"/>
	</junitreport>
    </target>

Anybody who can tell me what's the problem?

Thanks&Regards,
Bob

--
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