You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by ma...@apache.org on 2008/03/31 21:33:12 UTC

svn commit: r643112 - /ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java

Author: maartenc
Date: Mon Mar 31 12:33:10 2008
New Revision: 643112

URL: http://svn.apache.org/viewvc?rev=643112&view=rev
Log:
Attempt to fix the failing test on gump.

Modified:
    ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java

Modified: ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java?rev=643112&r1=643111&r2=643112&view=diff
==============================================================================
--- ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java (original)
+++ ant/ivy/core/trunk/test/java/org/apache/ivy/ant/IvyBuildListTest.java Mon Mar 31 12:33:10 2008
@@ -18,6 +18,9 @@
 package org.apache.ivy.ant;
 
 import java.io.File;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
 
 import junit.framework.TestCase;
 
@@ -521,10 +524,15 @@
                 .getAbsolutePath());
         assertEquals(new File("test/buildlist/D/build.xml").getAbsolutePath(), new File(files[3])
                 .getAbsolutePath());
-        assertEquals(new File("test/buildlist/E2/build.xml").getAbsolutePath(), new File(files[4])
-                .getAbsolutePath());
-        assertEquals(new File("test/buildlist/E/build.xml").getAbsolutePath(), new File(files[5])
-                .getAbsolutePath());
+        
+        // the order of E and E2 is undefined
+        List other = new ArrayList();
+        other.add(new File(files[4]).getAbsoluteFile().toURI());
+        other.add(new File(files[5]).getAbsoluteFile().toURI());
+        Collections.sort(other);
+        
+        assertEquals(new File("test/buildlist/E/build.xml").getAbsoluteFile().toURI(), other.get(0));
+        assertEquals(new File("test/buildlist/E2/build.xml").getAbsoluteFile().toURI(), other.get(1));
     }
     
 }