Skip to content

Commit 7f7340b

Browse files
committed
extra test
1 parent 07981a6 commit 7f7340b

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

base/src/test/java/net/time4j/range/MomentIntervalFormatTest.java

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,8 +604,19 @@ public void parseReducedISO1() throws ParseException {
604604
is(MomentInterval.between(start, end)));
605605
}
606606

607-
@Test(expected=ParseException.class)
607+
@Test
608608
public void parseReducedISO2() throws ParseException {
609+
MomentInterval range =
610+
MomentInterval.parseISO("2023-03-28T00:00:00+01:00/2023-03-29T06:00");
611+
Moment start = PlainTimestamp.of(2023, 3, 27, 23, 0).atUTC();
612+
Moment end = PlainTimestamp.of(2023, 3, 29, 5, 0).atUTC();
613+
assertThat(
614+
range,
615+
is(MomentInterval.between(start, end)));
616+
}
617+
618+
@Test(expected=ParseException.class)
619+
public void parseReducedISO3() throws ParseException {
609620
MomentInterval.parseISO("2023-03-28T00:00:00/06:00"); // missing time zone
610621
}
611622

0 commit comments

Comments
 (0)