@Test
public void successfulServiceInvocation() {
SuccessfulUpdateService successfulService = new SuccessfulUpdateService();
SearchIndexUpdateProgress progress;
Assert.assertNotNull(progress = successfulService.getProgress());
Assert.assertEquals(SearchIndexUpdateProgress.NOT_INITIALIZED, progress.getTotalOperations());
Assert.assertEquals(SearchIndexUpdateProgress.NOT_INITIALIZED, progress.getFinishedOperations());
successfulService.updateSearchIndex();
Assert.assertNotNull(progress = successfulService.getProgress());
Assert.assertEquals(SuccessfulUpdateService.TOTAL_CALCULATIONS, progress.getTotalOperations());
Assert.assertEquals(SuccessfulUpdateService.TOTAL_CALCULATIONS, progress.getFinishedOperations());
successfulService.reset();
Assert.assertNotNull(progress = successfulService.getProgress());
Assert.assertEquals(SearchIndexUpdateProgress.NOT_INITIALIZED, progress.getTotalOperations());
Assert.assertEquals(SearchIndexUpdateProgress.NOT_INITIALIZED, progress.getFinishedOperations());
}