@Test
public void testChangeTimeInstant() {

    TimeFrame timeFrame = TimeFrame.parse("now -1year till now");
    timeFrameEditor.init(timeFrame, changeCommand);
    when(timeInstantView.getSelectedIntervalTypeIndex()).thenReturn(3);
    fromInstantEditor.changeIntervalType();
    DateIntervalType type = timeFrame.getFrom().getIntervalType();
    verify(changeCommand).execute();
    assertEquals(type, DateIntervalType.MONTH);
}