@Test
public void testCollectionComparator() {

    List<Comparator> comparators = new ArrayList<Comparator>();
    comparators.add(new SimpleComparator());
    comparators.add(new CollectionComparator());
    comparators.add(new ObjectComparator());
    IntegratedComparator comparator = new IntegratedComparator(comparators);
    List<String> left = new ArrayList<String>();
    left.add("a");
    left.add("b");
    left.add("c");
    left.add("d");
    left.add("e");
    left.add("f");
    left.add("g");
    List<String> right = new ArrayList<String>();
    right.add("A");
    right.add("b");
    right.add("c");
    right.add("D");
    right.add("e");
    right.add("f");
    right.add("G");
    CompareResult result = comparator.compare(left, right);
    Assert.assertNotEquals(result, null);
    Assert.assertTrue(result.hasDifference());
    Assert.assertEquals(result.getDifferences().size(), 3);
    List<Student> leftStudents = new ArrayList<Student>();
    leftStudents.add(Student.builder()
            .name("java")
            .school("w3c")
            .age(10)
            .build());
    List<Student> rightStudents = new ArrayList<Student>();
    rightStudents.add(Student.builder()
            .name("java")
            .school("w3c")
            .age(12)
            .build());
    rightStudents.add(Student.builder()
            .name("java")
            .school("w3c")
            .age(12)
            .build());
    result = comparator.compare(leftStudents, rightStudents);
    Assert.assertNotEquals(result, null);
    Assert.assertTrue(result.hasDifference());
    Assert.assertEquals(result.getDifferences().size(), 2);
}