I need to compare two List, and in my test I used
assertEquals(lista1, lista2);
Assert.assertTrue(lista1.containsAll(lista2));
And the error that the test shows is
(index: 22 size: 22) java.lang.IndexOutOfBoundsException
Until today I had never tested a return from List so I do not know if I'm doing it right.