}
public void testMonthAndDayFrameUnevenBounds() throws Exception {
Calendar c = (Calendar) GregorianCalendar.getInstance().clone();
c.set(2000, Calendar.JANUARY, 16, 0, 0);
GregorianTimeUnitStack stack = new GregorianTimeUnitStack();
TimeUnit monthUnit = ((TimeUnitFunctionOfDate) GregorianTimeUnitStack.MONTH)
.createTimeUnit(c.getTime());
TimeUnit dayUnit = GregorianTimeUnitStack.DAY;
TimeFrame timeFrame = stack.createTimeFrame(c.getTime(), monthUnit,
dayUnit);
assertEquals("Unexpected number of monthes in the time frame="
+ timeFrame, 1, timeFrame.getUnitCount(monthUnit));
assertEquals(
"Unexpected number of days in the time frame=" + timeFrame, 16,