DateTimeZone.setDefault(DateTimeZone.forOffsetHours(OFFSET_HOURS));
}
public void testDeserializeLocalDate() throws JiBXException {
assertNull("Null input", JodaConvert.deserializeLocalDate(null));
LocalDate date = JodaConvert.deserializeLocalDate("2008-02-28");
assertEquals("Wrong value", 2008, date.getYear());
assertEquals("Wrong value", 2, date.getMonthOfYear());
assertEquals("Wrong value", 28, date.getDayOfMonth());
date = JodaConvert.deserializeLocalDate("2008-02-29Z");
assertEquals("Wrong value", 2008, date.getYear());
assertEquals("Wrong value", 2, date.getMonthOfYear());
assertEquals("Wrong value", 29, date.getDayOfMonth());
date = JodaConvert.deserializeLocalDate("2008-02-29-24:00");
assertEquals("Wrong value", 2008, date.getYear());
assertEquals("Wrong value", 2, date.getMonthOfYear());
assertEquals("Wrong value", 29, date.getDayOfMonth());
try {
JodaConvert.deserializeUTCDateTime("2007-02-29");
fail("Invalid day number");
} catch (JiBXException ex) {}
try {