ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jgl...@apache.org
Subject svn commit: r1222711 - /ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java
Date Fri, 23 Dec 2011 16:02:47 GMT
Author: jglick
Date: Fri Dec 23 16:02:47 2011
New Revision: 1222711

URL: http://svn.apache.org/viewvc?rev=1222711&view=rev
Log:
Should not throw an error if the temp dir does not yet exist.

Modified:
    ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java

Modified: ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java?rev=1222711&r1=1222710&r2=1222711&view=diff
==============================================================================
--- ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java
(original)
+++ ant/core/trunk/src/tests/junit/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregatorTest.java
Fri Dec 23 16:02:47 2011
@@ -41,7 +41,9 @@ public class XMLResultAggregatorTest ext
             return;
         }
         final File d = new File(System.getProperty("java.io.tmpdir"), "XMLResultAggregatorTest");
-        new Delete() {{removeDir(d);}}; // is there no utility method for this?
+        if (d.exists()) {
+            new Delete() {{removeDir(d);}}; // is there no utility method for this?
+        }
         assertTrue(d.getAbsolutePath(), d.mkdir());
         File xml = new File(d, "x.xml");
         PrintWriter pw = new PrintWriter(new FileOutputStream(xml));



Mime
View raw message