public void testIterator() {
   List<E> iteratorElements = new ArrayList<E>();
   for (E element : collection) { // uses iterator()
     iteratorElements.add(element);
   }
   Helpers.assertEqualIgnoringOrder(Arrays.asList(createSamplesArray()), iteratorElements);
 }
Beispiel #2
0
 public static void assertContentsAnyOrder(Iterable<?> actual, Object... expected) {
   assertEqualIgnoringOrder(Arrays.asList(expected), actual);
 }