@org.junit.Test public void testGetAllSorted() throws Exception { /*Resume[] src = new Resume[]{R1, R2, R3}; Arrays.sort(src); Assert.assertArrayEquals(src, storage.getAllSorted().toArray());*/ List<Resume> list = Arrays.asList(R1, R2, R3); Collections.sort( list, new Comparator<Resume>() { @Override public int compare(Resume o1, Resume o2) { return 0; } }); Assert.assertEquals(list, storage.getAllSorted()); }
@Test public void testGetAllSorted() throws Exception { List<Resume> list = Arrays.asList(ResumeTestData.R1, ResumeTestData.R2, ResumeTestData.R3); assertEquals(list, new ArrayList<>(storage.getAllSorted())); }