@Test public void testLogCompletedAgenda() throws PersistenceException { CaptureLogger logger = new CaptureLogger(); agendaProgressReporter.setLogger(logger); AgendaProgress agendaProgress = makeAgendaProgress("success"); agendaProgress.setCompletedTime(completedTime); agendaProgress.setStartedTime(startedTime); DataObjectResponse<AgendaProgress> response = mock(DataObjectResponse.class); when(response.getFirst()).thenReturn(agendaProgress); ObjectPersister<AgendaProgress> agendaProgressPersister = mock(ObjectPersister.class); when(agendaProgressPersister.retrieve(anyString())).thenReturn(agendaProgress); agendaProgressReporter.setAgendaProgressPersister(agendaProgressPersister); agendaProgressReporter.logCompletedAgenda(response); String logs = logger.getMsg(); AgendaValidator validator = new AgendaValidator(); validator.validateLogs(logs); }
public void logCompletedAgenda(DataObjectResponse<AgendaProgress> response) { logCompletedAgenda(response.getFirst()); }
AgendaProgressReporter { public void logCompletedAgenda(DataObjectResponse<AgendaProgress> response) { logCompletedAgenda(response.getFirst()); } }
AgendaProgressReporter { public void logCompletedAgenda(DataObjectResponse<AgendaProgress> response) { logCompletedAgenda(response.getFirst()); } AgendaProgressReporter( ObjectPersister<Agenda> agendaPersister); }
AgendaProgressReporter { public void logCompletedAgenda(DataObjectResponse<AgendaProgress> response) { logCompletedAgenda(response.getFirst()); } AgendaProgressReporter( ObjectPersister<Agenda> agendaPersister); void logCompletedAgenda(DataObjectResponse<AgendaProgress> response); void logCompletedAgenda(AgendaProgress partialAgendaProgress); void setAgendaProgressPersister(ObjectPersister<AgendaProgress> agendaProgressPersister); }
AgendaProgressReporter { public void logCompletedAgenda(DataObjectResponse<AgendaProgress> response) { logCompletedAgenda(response.getFirst()); } AgendaProgressReporter( ObjectPersister<Agenda> agendaPersister); void logCompletedAgenda(DataObjectResponse<AgendaProgress> response); void logCompletedAgenda(AgendaProgress partialAgendaProgress); void setAgendaProgressPersister(ObjectPersister<AgendaProgress> agendaProgressPersister);  }