@Test
public void testSetDateKeepsTime() {

    JXDatePicker picker = new JXDatePicker();
    DateSelectionModel selectionModel = new SingleDaySelectionModel();
    picker.getMonthView().setSelectionModel(selectionModel);
    Date date = new Date();
    selectionModel.setSelectionInterval(date, date);
    Date first = selectionModel.getFirstSelectionDate();
    assertEquals("formats diff: " + (date.getTime() - first.getTime())
            , date, first);
}