ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laura Dean <>
Subject Re: problem trying to set individual tests timeout
Date Fri, 14 Sep 2012 13:17:43 GMT
As I read it, that's the expected behavior:

   When running multiple tests inside the same Java VM (see forkMode),
   timeout applies to the time that all tests use together, not to an
   individual test.

You have forkMode set to once, which means you're running your tests in the
same JVM.

If you fork per test, you'll presumably get the desired behavior, so
perhaps that could work for you.  Or per batch, if only certain tests that
need this behavior.  (Or two separate junit tasks, or... it really depends
on what you're trying to do.)


On Wed, Sep 12, 2012 at 4:43 PM, vale <> wrote:

> Hi, I need to set individual test timeout. Im using the timeout option but
> when the time is over for an individual test it does not continue the
> execution of the rest of the suite. Any Idea what Im doing wrong? here is
> my
> code:
> <target name="runTest">
>                 <mkdir dir="${junit.output.dir}"/>
>                 <junit fork="true" forkmode="once"
> printsummary="withOutAndErr"
> haltonfailure="false"
>                            haltonerror="off" showoutput="true"
> timeout="60000">
>                     <formatter type="xml"/>
>                     <test name="EjemploTest" todir="${junit.output.dir}"/>
>                     <classpath refid="ejemplo.classpath"/>
>                 </junit>
>             </target>
> thanks in advance!
> --
> View this message in context:
> Sent from the Ant - Users mailing list archive at
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message