@Test
public void testHasPrev() throws Exception {

    RangeUnit unit = mock(RangeUnit.class);
    when(unit.hasPrev()).thenReturn(true);
    mCalendarManager.setUnit(unit);
    boolean result = mCalendarManager.hasPrev();
    assertTrue(result);
    verify(unit).hasPrev();
}