### Question:
DateExtractionHelper { public static <D extends ExtractedDate> List<D> filterExactest(List<D> dates) { DateExactness highestExactness = DateExactness.UNSET; for (D date : dates) { DateExactness currentExactness = date.getExactness(); if (currentExactness.provides(highestExactness)) { highestExactness = currentExactness; } } List<D> result = new ArrayList<>(); for (D date : dates) { if (date.getExactness() == highestExactness) { result.add(date); } } return result; } private  DateExtractionHelper(); static List<T> filter(List<? extends ExtractedDate> dates, Class<T> filter); static List<T> filterByRange(List<T> dates); static List<T> filterFullDate(List<T> dates); static List<List<T>> cluster(List<T> dates, DateExactness compareDepth); static int countDates(ExtractedDate date, List<? extends ExtractedDate> dates, DateExactness exactness); static List<E> getRatedDates(List<RatedDate<E>> dates, double rate); static List<D> filterExactest(List<D> dates); static double getHighestRate(List<? extends RatedDate<?>> ratedDates); static boolean isDateInRange(ExtractedDate date); static List<RatedDate<T>> setRate(List<T> dates, double rate);  }### Answer:
@Test public void testGetExactest() { ExtractedDate date1 = DateParser.parseDate("2012-08", RegExp.DATE_ISO8601_YM); ExtractedDate date2 = DateParser.parseDate("2012-09", RegExp.DATE_ISO8601_YM); ExtractedDate date3 = DateParser.parseDate("2012-08-28", RegExp.DATE_ISO8601_YMD_SEPARATOR); ExtractedDate date4 = DateParser.parseDate("2012-08-29", RegExp.DATE_ISO8601_YMD_SEPARATOR); ExtractedDate date5 = DateParser.parseDate("2012-08-30 12:05:30", RegExp.DATE_ISO8601_YMD_T); ExtractedDate date6 = DateParser.parseDate("2012-08-30 12:05:31", RegExp.DATE_ISO8601_YMD_T); ExtractedDate date7 = DateParser.parseDate("2012-08-30", RegExp.DATE_ISO8601_YMD_SEPARATOR); List<ExtractedDate> dateList = Arrays.asList(date1, date2, date3, date4, date5, date6, date7); List<ExtractedDate> exactestDates = DateExtractionHelper.filterExactest(dateList); assertEquals(2, exactestDates.size()); assertEquals(date5, exactestDates.get(0)); assertEquals(date6, exactestDates.get(1)); }