Method Summary |
|
protected void | setUp() Common test setup. |
public static Test | suite() Returns the tests as a test suite. |
public void | testBug1448828() A test case for bug 1448828. |
public void | testBug1498805() A test case for bug 1498805. |
public void | testEquals() Tests the equals method. |
public void | testGetEnd() Some checks for the getEnd() method. |
public void | testGetFirstMillisecond() Some checks for the getFirstMillisecond() method. |
public void | testGetFirstMillisecondWithCalendar() Some checks for the getFirstMillisecond(TimeZone) method. |
public void | testGetFirstMillisecondWithTimeZone() Some checks for the getFirstMillisecond(TimeZone) method. |
public void | testGetLastMillisecond() Some checks for the getLastMillisecond() method. |
public void | testGetLastMillisecondWithCalendar() Some checks for the getLastMillisecond(TimeZone) method. |
public void | testGetLastMillisecondWithTimeZone() Some checks for the getLastMillisecond(TimeZone) method. |
public void | testGetSerialIndex() Some checks for the getSerialIndex() method. |
public void | testGetStart() Some checks for the getStart() method. |
public void | testHashcode() Two objects that are equal are required to return the same hashCode. |
public void | testNext() Some checks for the testNext() method. |
public void | testNotCloneable() The
Week class is immutable, so should not be
Cloneable . |
public void | testSerialization() Serialize an instance, restore it, and check for equality. |
public void | testW1Y1900Next() Request the week after week 1, 1900: it should be week 2, 1900. |
public void | testW1Y1900Previous() Request the week before week 1, 1900: it should be null . |
public void | testW52Y9999Next() Request the week after w52, 9999: it should be null . |
public void | testW52Y9999Previous() Request the week before w52, 9999: it should be week 51, 9999. |
public void | testWeek12005() The first week in 2005 should span the range:
TimeZone | Start Millis | End Millis | Start Date | End Date
-----------------+---------------+---------------+-------------+------------
Europe/London | 1104710400000 | 1105315199999 | 3-Jan-2005 | 9-Jan-2005
Europe/Paris | 1104706800000 | 1105311599999 | 3-Jan-2005 | 2-Jan-2005
America/New_York | 1104037200000 | 1104641999999 | 26-Dec-2004 | 1-Jan-2005
In London and Paris, Monday is the first day of the week, while in the
US it is Sunday. |
public void | testWeek532005() The 53rd week in 2004 in London and Paris should span the range:
TimeZone | Start Millis | End Millis | Start Date | End Date
-----------------+---------------+---------------+-------------+------------
Europe/London | 1104105600000 | 1104710399999 | 27-Dec-2004 | 02-Jan-2005
Europe/Paris | 1104102000000 | 1104706799999 | 27-Dec-2004 | 02-Jan-2005
The 53rd week in 2005 in New York should span the range:
TimeZone | Start Millis | End Millis | Start Date | End Date
-----------------+---------------+---------------+-------------+------------
America/New_York | 1135486800000 | 1136091599999 | 25-Dec-2005 | 31-Dec-2005
In London and Paris, Monday is the first day of the week, while in the
US it is Sunday. |