ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Levy Lambert <>
Subject Re: svn commit: r1580520 - in /ant/core/trunk: ./ manual/Tasks/ src/main/org/apache/tools/ant/taskdefs/optional/junit/
Date Sun, 30 Mar 2014 23:49:29 GMT

I have had a first shot at creating temporary folders with names including the current PID
and the current Thread Name in order 
to allow to run tests in parallel. I did not have the time today to do the work for all the
Ant test cases but it seems achievable to finish that work.

On Mar 24, 2014, at 1:08 AM, Stefan Bodewig <> wrote:

> On 2014-03-23, Antoine Levy Lambert wrote:
>> Some of our test cases do not support parallelism because they are creating and dropping
temporary directories and files which have the same names.
> On first glance there also may be a race condition for the test that
> expects certain build events.  See the Jenkins test error on JDK8 - and
> the nightly, I suspect, but Jenkins is currently down.
this error happened once, I do not know exactly what caused it, the next build was green.
>> I was thinking of adding somewhere in the Ant codebase a utility class
>> or method to get the PID of the currently running process and add the
>> PID somewhere in the name of temporary folders created for tests.
> Yes, unique temporary directory names is the best you can do.  I haven't
> looked at the code, yet.  From the name of the attribute I would have
> expected multiple threads inside the same VM rather than multiple
> processes.  In the case of the same VM you'd certainly use the Thread-Id
> or name instead.
This JUnit multi-thread implementation is currently working if you choose fork=true and forkMode=perTest.
> You may want to move test directory creation/deletion into BuildFileTest
> similar to what we do with antunit-base.
I have added the setting of properties and ant.threadname in BuildFileTest, these
properties are then used
to give a name to a temporary folder ${output} in a new base build file similar to what exists
for the AntUnit tests.
> Stefan


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

View raw message