ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harkness, David" <>
Subject RE: Junit Output
Date Wed, 25 Jun 2003 00:00:43 GMT
I just got running with Junit, but I haven't tried using the XML
formatter yet. However, I did notice a few things about this that I'd
check out on your end. It could be my misunderstanding, however. Note,
also, that I wasn't able to get fork working, though I only spent a few
minutes looking into it.

1. Is it okay to use two formatters? Will it simply pipe to both?
2. Your output dir is ${testoutput.dir} yet your fileset is specified as
".". I believe that a fileset's base directory is always the same as the
project's. That it appears in the junitreport with a todir argument
shouldn't make a difference.

I suggest reposting your question with the relevant Ant output to make
diagnosing the problem easier for the others.

Good luck!

David Harkness
Sony Pictures Digital Networks

-----Original Message-----
From: Jacqui Guerrero [] 
Sent: Tuesday, June 24, 2003 9:42 AM
To: Ant Mailing List
Subject: Junit Output


I am running junit tests within ant but it seems that no output is
written to the test xml that gets generated for the test cases.  Am I
doing something wrong?  Below is my <junit> task:

<target name="runtests">
    <echo message="Running tests" />
    <junit printsummary="withOutAndErr"

        <formatter type="brief" usefile="false" />

        <!-- Start VM arguments -->
        <jvmarg value="-Dgroxis.grokker.common.dir=common"/>
        <jvmarg value="-Dgroxis.grokker.user.dir=c:\Documents and
        <jvmarg value="-Dgroxis.grokker.maps.dir=Maps"/>
        <jvmarg value="-Dgroxis.grokker.settings.dir=Settings"/>
        <jvmarg value="-Dgroxis.grokker.preferences.dir=Preferences"/>
        <jvmarg value="-Dgroxis.grokker.plugins.dir=plugins"/>
        <jvmarg value="-Dgroxis.grokker.document.dir=doc"/>
        <jvmarg value="-Dgroxis.grokker.user.maps.dir=Maps"/>
        <jvmarg value="-Dgroxis.grokker.user.settings.dir=Settings"/>
        <jvmarg value="-Dgroxis.grokker.user.plugins.dir=plugins"/>
        <jvmarg value="-Dgroxis.grokker.startUrl=blank.html"/>
        <jvmarg value="-Dgroxis.grokker.resources.dir=resources"/>
        <jvmarg value="-Dgroxis.grokker.jarFile=Grokker.jar"/>
        <jvmarg value="-Dgroxis.grokker.webserver=false"/>
        <!-- End VM arguments -->

        <formatter type="xml"/>
        <test fork="yes" todir="${testoutput.dir}"
name="com.groxis.test.product.grokker.BrowsePanelTest" />
        <test fork="yes" todir="${testoutput.dir}"
name="com.groxis.test.product.grokker.MarkNodeTest" />

        <classpath refid="project.class.path" />

    <junitreport todir="${testoutput.dir}">
        <fileset dir=".">
            <include name="TEST-*.xml" />
        <report format="frames" todir="${testoutput.dir}/suites"/>

    <fail message="Tests failed. Check log and/or reports."
if="test.failed" /> </target>


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

View raw message