@Test public void testGetAllPodcasts() throws IOException, ParserConfigurationException, InvalidRssFeedException, InvalidDateFormatException, SAXException, NotFoundException { Feed actualFeed = rssFeedService.getRssFeedPodcasts(false); assertNotNull("Feed Object should not be null ", actualFeed); assertEquals(5, actualFeed.getPodcasts().size()); assertEquals("1", actualFeed.getPodcasts().get(0).getId()); }
@Test public void testGetMostRecentPodcast() throws IOException, ParserConfigurationException, InvalidRssFeedException, InvalidDateFormatException, SAXException, NotFoundException { Feed actualFeed = rssFeedService.getRssFeedPodcasts(true); assertNotNull("Feed Object should not be null ", actualFeed); assertEquals(1, actualFeed.getPodcasts().size()); String actualMostRecentDate = DateUtils.convertDateToGMTString(actualFeed.getPodcasts().get(0).getPubDate()); assertEquals(ACTUAL_MOST_RECENT_DATE, actualMostRecentDate); }