test/java/fr/jayasoft/ivy/SortTest.java
// because circular dependencies are more complicated to evaluate than just a callstack comparison

because circular dependencies are more complicated to evaluate than just a callstack comparison
because circular dependencies are more complicated to evaluate than just a callstack comparison
public void testCircularDependency() throws Exception {
        Ivy ivy = new Ivy();
        ivy.configureDefault();
        md[0].addDependency(new DefaultDependencyDescriptor(mrid4, false));
        toSort = new ArrayList(Arrays.asList(new Object[] {md[0], md[2], md[1], md[3]}));
        DefaultModuleDescriptor[] sorted = new DefaultModuleDescriptor[] {
                md[1], md[2], md[3], md[0]
            };
        assertSorted(sorted, ivy.sortModuleDescriptors(toSort));
    }
public void testCircularDependency ( ) throws Exception { Ivy ivy = new Ivy ( ) ; ivy . configureDefault ( ) ; md [ 0 ] . addDependency ( new DefaultDependencyDescriptor ( mrid4 , false ) ) ; toSort = new ArrayList ( Arrays . asList ( new Object [ ] { md [ 0 ] , md [ 2 ] , md [ 1 ] , md [ 3 ] } ) ) ; DefaultModuleDescriptor [ ] sorted = new DefaultModuleDescriptor [ ] { md [ 1 ] , md [ 2 ] , md [ 3 ] , md [ 0 ] } ; assertSorted ( sorted , ivy . sortModuleDescriptors ( toSort ) ) ; }
because circular dependencies are more complicated to evaluate than just a callstack comparison
because circular dependencies are more complicated to evaluate than just a callstack comparison
// the sorted array may begin by any of the modules since there is a circular dependency
 // in this case, the result is the following
