[threeten-dev] Please help to review new test cases for java.time.chrono.MinguoChronology
Stephen Colebourne
scolebourne at joda.org
Tue Mar 5 05:32:05 PST 2013
Looks good to me.
thanks
Stephen
On 5 March 2013 06:58, patrick zhang <patrick.zhang at oracle.com> wrote:
> Hi Team,
>
> Please help to review new added test for missed api in
> java.time.chrono.MinguoChronology.
> As one initial review version, the webrev includes MinguoChronology only.
> Similar test logic will be applied to IsoChronology, HijrahChronology and
> JapaneseChronology in future webrev.
>
> Description:
> 1. check new factory method.
> date(Era era, int yearOfEra, int month, int dayOfMonth)
> dateYearDay(Era era, int yearOfEra, int dayOfYear)
> 2. check now() related function in MinguoChronology and MinguoDate.
> dateNow()
> dateNow(Clock clock)
> dateNow(ZoneId zone)
> 3. check localDateTime(TemporalAccessor temporal) and
> zonedDateTime(TemporalAccessor temporal)
> In jsr310, we have 3 datetime classes which implements TemporalAccessor:
> LocalDateTime, OffsetDateTime and ZonedDateTime
> According to description in javadoc, all 3 classes can be used in
> localDateTime(TemporalAccessor temporal). But LocalDateTime can not be used
> in zonedDateTime(TemporalAccessor temporal) since it does not contain one
> Offset. All other TemporalAccessor should throws DataTimeException for both
> methods.
> Above logic have been verified in test_localDateTime() and
> test_zonedDateTime().
> 4. check zonedDateTime(Instant instant, ZoneId zone)
> See test_Instant_zonedDateTime(). Similar with test_zonedDateTime()
>
>
> webrev:
> http://cr.openjdk.java.net/~pzhang/JSR310/java/time/chrono/MinguoChronology/webrev/
>
> test result:
> http://cr.openjdk.java.net/~pzhang/JSR310/java/time/chrono/MinguoChronology/TestMinguoChronology.jtr
>
> Regards
> Patrick
>
More information about the threeten-dev
mailing list