@@ -230,7 +230,7 @@ public void testRoundMonthOfYear() {
230230 assertThat (DateUtils .roundMonthOfYear (-1 ), is (dec1969 ));
231231
232232 IllegalArgumentException exc = expectThrows (IllegalArgumentException .class , () -> DateUtils .roundIntervalMonthOfYear (0 , -1 ));
233- assertThat (exc .getMessage (), is ("month interval [-1] must be positive" ));
233+ assertThat (exc .getMessage (), is ("month interval must be strictly positive, got [-1] " ));
234234 assertThat (DateUtils .roundIntervalMonthOfYear (1 , 5 ), is (0L ));
235235 long epochMilli = LocalDate .of (1969 , 7 , 1 ).atStartOfDay ().toInstant (ZoneOffset .UTC ).toEpochMilli ();
236236 assertThat (DateUtils .roundIntervalMonthOfYear (-1 , 13 ), is (epochMilli ));
@@ -251,7 +251,7 @@ public void testRoundYear() {
251251 assertThat (DateUtils .roundYear (endOf1996 ), is (startOf1996 ));
252252
253253 IllegalArgumentException exc = expectThrows (IllegalArgumentException .class , () -> DateUtils .roundYearInterval (0 , -1 ));
254- assertThat (exc .getMessage (), is ("year interval [-1] must be positive" ));
254+ assertThat (exc .getMessage (), is ("year interval must be strictly positive, got [-1] " ));
255255 assertThat (DateUtils .roundYearInterval (0 , 2 ), is (startOf1969 ));
256256 long startOf1968 = Year .of (1968 ).atDay (1 ).atStartOfDay ().toInstant (ZoneOffset .UTC ).toEpochMilli ();
257257 assertThat (DateUtils .roundYearInterval (0 , 7 ), is (startOf1968 ));
@@ -270,7 +270,7 @@ public void testRoundWeek() {
270270 assertThat (DateUtils .roundWeekOfWeekYear (-1 ), is (epochMilli ));
271271
272272 IllegalArgumentException exc = expectThrows (IllegalArgumentException .class , () -> DateUtils .roundWeekIntervalOfWeekYear (0 , -1 ));
273- assertThat (exc .getMessage (), is ("week interval [-1] must be positive" ));
273+ assertThat (exc .getMessage (), is ("week interval must be strictly positive, got [-1] " ));
274274 assertThat (DateUtils .roundWeekIntervalOfWeekYear (0 , 3 ), is (epochMilli ));
275275 assertThat (DateUtils .roundWeekIntervalOfWeekYear (1 , 3 ), is (epochMilli ));
276276 assertThat (DateUtils .roundWeekIntervalOfWeekYear (-1 , 2 ), is (epochMilli ));
0 commit comments