use of com.thoughtworks.go.domain.feed.stage.StageFeedEntry in project gocd by gocd.
the class StageAtomFeedsReaderTest method canGetAllStageUrlsInAStagesFeed.
@Test
public void canGetAllStageUrlsInAStagesFeed() throws Exception {
when(stageDao.findAllCompletedStages(FeedModifier.Latest, -1, StageAtomFeedsReader.PAGE_SIZE)).thenReturn(Arrays.asList(feedEntry(2), feedEntry(1)));
new StageAtomFeedsReader(stageDao).readFromLatest(stageFeedHandler, pipelineInstanceLoader);
List<StageFeedEntry> list = stageFeedHandler.handledFeeds();
assertEquals(2, list.size());
assertEquals(2, list.get(0).getId());
assertEquals(1, list.get(1).getId());
}
Aggregations