public void testLastModifiedDatePrefersReleasedDateIfNoChanges() throws Exception { a3.setReleasedDate(DateTools.createDate(2007, Calendar.OCTOBER, 20)); a3.addDelta(new EpochDelta()); assertDayOfDate(2007, Calendar.OCTOBER, 20, a3.getLastModifiedDate()); }
public void testLastModifiedDatePrefersUpdatedDateIfReleasedDateNull() throws Exception { a3.setReleasedDate(null); ensureUpdatedDate(a3, DateTools.createDate(2007, Calendar.OCTOBER, 20)); assertDayOfDate(2007, Calendar.OCTOBER, 20, a3.getLastModifiedDate()); }
public void testLastModifiedDatePrefersReleasedDateIfNoDeltas() throws Exception { a3.setReleasedDate(DateTools.createDate(2007, Calendar.OCTOBER, 20)); a3.getDeltas().clear(); assertDayOfDate(2007, Calendar.OCTOBER, 20, a3.getLastModifiedDate()); }
public void testLastModifiedDateIsNullIfAllDatesAreNull() throws Exception { a3.setReleasedDate(null); ensureUpdatedDate(a3, null); assertNull(a3.getLastModifiedDate()); }