You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Richard Liang (JIRA)" <ji...@apache.org> on 2007/01/31 08:52:05 UTC

[jira] Resolved: (HARMONY-2947) [classlib][luni]GregorianCalendar.getLeastMaximum(Calendar.WEEK_OF_YEAR) always return 50

     [ https://issues.apache.org/jira/browse/HARMONY-2947?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Richard Liang resolved HARMONY-2947.
------------------------------------

    Resolution: Fixed

Hello Tony,

The patch has been applied at revision r501757. Thank you for this enhancement. Please verify this issue is fixed as you expected.

Best regards,
Richard

> [classlib][luni]GregorianCalendar.getLeastMaximum(Calendar.WEEK_OF_YEAR) always return 50
> -----------------------------------------------------------------------------------------
>
>                 Key: HARMONY-2947
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2947
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Tony Wu
>         Assigned To: Richard Liang
>         Attachments: harmony-2947.diff
>
>
> GregorianCalendar.getLeastMaximum(Calendar.WEEK_OF_YEAR) always return 50 in Harmony.
> But spec says that it should take into consideration the current values of the getFirstDayOfWeek, getMinimalDaysInFirstWeek, getGregorianChange and getTimeZone methods.
> For example, following testcase fails on Harmony but passes on RI.
> public void test() {
>         Date date = new Date(Date.parse("Jan 1 00:00:01 GMT 2000"));
>         GregorianCalendar gc = new GregorianCalendar();
>         gc.setGregorianChange(date);
>         gc.setMinimalDaysInFirstWeek(7);
>         assertEquals(52, gc.getLeastMaximum(Calendar.WEEK_OF_YEAR));
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.