|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.opensubsystems.core.util.DateUtilsTest
public class DateUtilsTest
Tests for common operations with dates.
| Field Summary | |
|---|---|
protected java.text.DateFormat |
m_dateTimeFormat
Formatter to format dates and times; |
| Constructor Summary | |
|---|---|
DateUtilsTest(java.lang.String arg0)
Constructor for DateUtilsTest. |
|
| Method Summary | |
|---|---|
protected void |
setUp()
Set up environment for the test case. |
protected void |
tearDown()
Restore original environment after the test case. |
void |
testDateAndTimeEquals()
Test comparison of two equal date times. |
void |
testDateAndTimeEqualsFirstNull()
Test comparison of null and date time. |
void |
testDateAndTimeEqualsNullAndNull()
Test comparison of null and null. |
void |
testDateAndTimeEqualsSecondNull()
Test comparison of date time and null. |
void |
testDateAndTimeEqualsWithDayDiff()
Test comparison of two date times which differ in day. |
void |
testDateAndTimeEqualsWithEraDiff()
Test comparison of two date times which differ in era. |
void |
testDateAndTimeEqualsWithHourDiff()
Test comparison of two date times which differ in hour. |
void |
testDateAndTimeEqualsWithMilliDiff()
Test comparison of two date times which differ in milliseconds. |
void |
testDateAndTimeEqualsWithMinuteDiff()
Test comparison of two date times which differ in minutes. |
void |
testDateAndTimeEqualsWithMonthDiff()
Test comparison of two date times which differ in month. |
void |
testDateAndTimeEqualsWithSecondDiff()
Test comparison of two date times which differ in seconds. |
void |
testDateAndTimeEqualsWithTheSameObject()
Test comparison of the same date time object. |
void |
testDateAndTimeEqualsWithYearDiff()
Test comparison of two date times which differ in year. |
void |
testDateEquals()
Test comparison of two equal dates. |
void |
testDateEqualsFirstNull()
Test comparison of null and date. |
void |
testDateEqualsNullAndNull()
Test comparison of null and null. |
void |
testDateEqualsSecondNull()
Test comparison of date and null. |
void |
testDateEqualsWithDayDiff()
Test comparison of two dates which differ in day. |
void |
testDateEqualsWithEraDiff()
Test comparison of two dates which differ in era. |
void |
testDateEqualsWithHourDiff()
Test comparison of two dates which differ in hour. |
void |
testDateEqualsWithMilliDiff()
Test comparison of two dates which differ in milliseconds. |
void |
testDateEqualsWithMinuteDiff()
Test comparison of two dates which differ in minutes. |
void |
testDateEqualsWithMonthDiff()
Test comparison of two dates which differ in month. |
void |
testDateEqualsWithSecondDiff()
Test comparison of two dates which differ in seconds. |
void |
testDateEqualsWithTheSameObject()
Test comparison of the same date object. |
void |
testDateEqualsWithYearDiff()
Test comparison of two dates which differ in year. |
void |
testTimeEquals()
Test comparison of two equal times. |
void |
testTimeEqualsFirstNull()
Test comparison of null and time. |
void |
testTimeEqualsNullAndNull()
Test comparison of null and null. |
void |
testTimeEqualsSecondNull()
Test comparison of time and null. |
void |
testTimeEqualsWithDayDiff()
Test comparison of two times which differ in day. |
void |
testTimeEqualsWithEraDiff()
Test comparison of two dates which differ in era. |
void |
testTimeEqualsWithHourDiff()
Test comparison of two times which differ in hours. |
void |
testTimeEqualsWithMilliDiff()
Test comparison of two times which differ in milliseconds. |
void |
testTimeEqualsWithMilliDiffIgnored()
Test comparison of two times which differ in milliseconds and ignoring the milliseconds. |
void |
testTimeEqualsWithMinuteDiff()
Test comparison of two times which differ in minutes. |
void |
testTimeEqualsWithMonthDiff()
Test comparison of two dates which differ in month. |
void |
testTimeEqualsWithSecondDiff()
Test comparison of two dates which differ in seconds. |
void |
testTimeEqualsWithTheSameObject()
Test comparison of the same time object. |
void |
testTimeEqualsWithYearDiff()
Test comparison of two dates which differ in year. |
| Methods inherited from class junit.framework.TestCase |
|---|
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString |
| Methods inherited from class junit.framework.Assert |
|---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected java.text.DateFormat m_dateTimeFormat
| Constructor Detail |
|---|
public DateUtilsTest(java.lang.String arg0)
arg0 - - name of the test| Method Detail |
|---|
protected void setUp()
throws java.lang.Exception
setUp in class junit.framework.TestCasejava.lang.Exception - - an error has occured during setting up test
protected void tearDown()
throws java.lang.Exception
tearDown in class junit.framework.TestCasejava.lang.Exception - - an error has occured during tearing down up testpublic void testDateEquals()
public void testDateEqualsFirstNull()
public void testDateEqualsSecondNull()
public void testDateEqualsNullAndNull()
public void testDateEqualsWithTheSameObject()
public void testDateEqualsWithMilliDiff()
public void testDateEqualsWithSecondDiff()
public void testDateEqualsWithMinuteDiff()
public void testDateEqualsWithHourDiff()
public void testDateEqualsWithDayDiff()
public void testDateEqualsWithMonthDiff()
public void testDateEqualsWithYearDiff()
public void testDateEqualsWithEraDiff()
public void testDateAndTimeEquals()
public void testDateAndTimeEqualsFirstNull()
public void testDateAndTimeEqualsSecondNull()
public void testDateAndTimeEqualsNullAndNull()
public void testDateAndTimeEqualsWithTheSameObject()
public void testDateAndTimeEqualsWithMilliDiff()
public void testDateAndTimeEqualsWithSecondDiff()
public void testDateAndTimeEqualsWithMinuteDiff()
public void testDateAndTimeEqualsWithHourDiff()
public void testDateAndTimeEqualsWithDayDiff()
public void testDateAndTimeEqualsWithMonthDiff()
public void testDateAndTimeEqualsWithYearDiff()
public void testDateAndTimeEqualsWithEraDiff()
public void testTimeEquals()
public void testTimeEqualsFirstNull()
public void testTimeEqualsSecondNull()
public void testTimeEqualsNullAndNull()
public void testTimeEqualsWithTheSameObject()
public void testTimeEqualsWithMilliDiff()
public void testTimeEqualsWithMilliDiffIgnored()
public void testTimeEqualsWithSecondDiff()
public void testTimeEqualsWithMinuteDiff()
public void testTimeEqualsWithHourDiff()
public void testTimeEqualsWithDayDiff()
public void testTimeEqualsWithMonthDiff()
public void testTimeEqualsWithYearDiff()
public void testTimeEqualsWithEraDiff()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||