*/
@Test
@SuppressWarnings("nls")
public void testAtom() throws Exception {
InputStream inS = getClass().getResourceAsStream("/data/interpreter/feed_atom.xml");
IFeed feed = new Feed(new URI("http://www.data.interpreter.feed_atom.xml"));
Owl.getInterpreter().interpret(inS, feed, null);
assertEquals("Atom 1.0", feed.getFormat());
assertEquals("atom_title", feed.getTitle());
assertEquals("atom_subtitle", feed.getDescription());
assertEquals(new URI("atom_link_html"), feed.getHomepage());
assertEquals("atom_generator", feed.getGenerator());
assertEquals("en-us", feed.getLanguage());
assertEquals(new URI("http://www.feed-uri.de"), feed.getBase());
assertNotNull(feed.getImage());
assertEquals(new URI("atom_logo"), feed.getImage().getLink());
assertNotNull(feed.getLastModifiedDate());
assertEquals(1, feed.getCategories().size());
assertEquals("atom_category.label", feed.getCategories().get(0).getName());
assertEquals("atom_category.term", feed.getCategories().get(0).getDomain());
assertEquals("atom_copyright", feed.getCopyright());
assertNotNull(feed.getAuthor());
assertEquals("atom_author.name", feed.getAuthor().getName());
assertEquals(new URI("atom_author.uri"), feed.getAuthor().getUri());
assertEquals(new URI("atom_author.email"), feed.getAuthor().getEmail());
assertEquals(6, feed.getNews().size());
INews news1 = feed.getNews().get(0);
assertEquals("atom_entry1.title", news1.getTitle());
assertEquals("atom_entry1.description", news1.getDescription());
assertEquals(new URI("http://www.entry-uri.de"), news1.getBase());
assertNotNull(news1.getCategories());
assertEquals("atom_entry1.category.label", news1.getCategories().get(0).getName());
assertEquals("atom_entry1.category.term", news1.getCategories().get(0).getDomain());
assertNotNull(news1.getGuid());
assertEquals("atom_entry1.id", news1.getGuid().getValue());
assertEquals(new URI("atom_entry1.link.href"), news1.getLink());
assertEquals(2, news1.getAttachments().size());
assertEquals(new URI("atom_entry1.enclosure1.href"), news1.getAttachments().get(0).getLink());
assertEquals("mp3", news1.getAttachments().get(0).getType());
assertEquals(4500000, news1.getAttachments().get(0).getLength());
assertEquals(new URI("atom_entry1.enclosure2.href"), news1.getAttachments().get(1).getLink());
assertEquals("wav", news1.getAttachments().get(1).getType());
assertEquals(2500000, news1.getAttachments().get(1).getLength());
assertNotNull(news1.getPublishDate());
assertNotNull(news1.getModifiedDate());
assertNotNull(news1.getSource());
assertEquals("atom_entry1.source.title", news1.getSource().getName());
assertEquals(new URI("atom_entry1.source.id"), news1.getSource().getLink());
assertNotNull(news1.getAuthor());
assertEquals("atom_entry1.author.name", news1.getAuthor().getName());
assertEquals(new URI("atom_entry1.author.uri"), news1.getAuthor().getUri());
assertEquals(new URI("atom_entry1.author.email"), news1.getAuthor().getEmail());
INews news2 = feed.getNews().get(1);
assertEquals("<p>atom_entry2.title</p>", news2.getTitle());
assertEquals("<p>atom_entry2.description</p>", news2.getDescription());
assertEquals(new URI("http://www.feed-uri.de/subfolder"), news2.getBase());
assertNotNull(news2.getSource());
assertEquals(new URI("atom_entry2.source.link"), news2.getSource().getLink());
INews news3 = feed.getNews().get(2);
assertEquals("<p xmlns=\"http://www.w3.org/1999/xhtml\">atom_entry3.title</p>", news3.getTitle());
assertEquals("<p xmlns=\"http://www.w3.org/1999/xhtml\">atom_entry3.description</p>", news3.getDescription());
assertEquals(new URI("http://www.feed-uri.de"), news3.getBase());
INews news4 = feed.getNews().get(3);
assertEquals(new URI("atom_entry4.link.href"), news4.getLink());
INews news5 = feed.getNews().get(4);
assertEquals("<p xmlns=\"http://www.w3.org/1999/xhtml\">atom_entry5.title</p>", news5.getTitle());
assertEquals("<p xmlns=\"http://www.w3.org/1999/xhtml\">atom_entry5.description</p>", news5.getDescription());
INews news6 = feed.getNews().get(5);
assertEquals("<p>atom_entry6.title</p>", news6.getTitle());
}