harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chen Shunfei (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-4863) Bug found on java.util
Date Thu, 27 Sep 2007 08:40:50 GMT

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

Chen Shunfei updated HARMONY-4863:
----------------------------------

    Description: 
This failure only happens on Linux. Here is the test case of Junit

import junit.framework.TestCase;
import java.util.Calendar;
import java.util.TimeZone;
import java.util.Date;
public class TestTimeZone extends TestCase{
	public void testTimeZone() throws Throwable{
	    Calendar calendar = Calendar.getInstance();
	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+0"));
	    int timeOne= calendar.get(Calendar.HOUR_OF_DAY);
	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+15"));
	    int timeTwo = calendar.get(java.util.Calendar.HOUR_OF_DAY);
	    int i = timeTwo-timeOne;
	    assertEquals(i,15);
	}
}

  was:
Here is the test case of Junit

import junit.framework.TestCase;
import java.util.Calendar;
import java.util.TimeZone;
import java.util.Date;
public class TestTimeZone extends TestCase{
	public void testTimeZone() throws Throwable{
	    Calendar calendar = Calendar.getInstance();
	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+0"));
	    int timeOne= calendar.get(Calendar.HOUR_OF_DAY);
	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+15"));
	    int timeTwo = calendar.get(java.util.Calendar.HOUR_OF_DAY);
	    int i = timeTwo-timeOne;
	    assertEquals(i,15);
	}
}


> Bug found on java.util
> ----------------------
>
>                 Key: HARMONY-4863
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4863
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Linux Ubuntu
> harmony-jre-567890
>            Reporter: Chen Shunfei
>            Priority: Minor
>
> This failure only happens on Linux. Here is the test case of Junit
> import junit.framework.TestCase;
> import java.util.Calendar;
> import java.util.TimeZone;
> import java.util.Date;
> public class TestTimeZone extends TestCase{
> 	public void testTimeZone() throws Throwable{
> 	    Calendar calendar = Calendar.getInstance();
> 	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+0"));
> 	    int timeOne= calendar.get(Calendar.HOUR_OF_DAY);
> 	    calendar.setTimeZone(TimeZone.getTimeZone("GMT+15"));
> 	    int timeTwo = calendar.get(java.util.Calendar.HOUR_OF_DAY);
> 	    int i = timeTwo-timeOne;
> 	    assertEquals(i,15);
> 	}
> }

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


Mime
View raw message