Beispiel #1
0
 @Test
 public void testPlusDaysOverflow() throws Exception {
   try {
     testDate.plusDays(Integer.MAX_VALUE);
     fail();
   } catch (IllegalCalendarFieldValueException ex) {
     assertEquals(ex.getRule(), MinguoChronology.yearOfEraRule());
   }
 }
Beispiel #2
0
 // -----------------------------------------------------------------------
 // plusDays()
 // -----------------------------------------------------------------------
 @Test
 public void testPlusDays() {
   assertEquals(
       testDate.plusDays(2), MinguoDate.of(testYear, testMonthOfYear, testDayOfMonth + 2));
 }