assertTrue(entries.size() == 1);
StringWriter theXMLString = new StringWriter();
XMLStreamWriter writer = XMLOutputFactory.newInstance()
.createXMLStreamWriter(theXMLString);
new FeedWriter().writeEntries(writer, entries);
writer.flush();
writer.close();
assertEquals(theXMLString.toString(), entry1Result);
entries = new FeedReader(feedDoc).readEntry(XMLInputFactory
.newInstance().createXMLStreamReader(
new StringReader(entry2)), null);
assertTrue(entries != null);
assertTrue(entries.size() == 1);
theXMLString = new StringWriter();
writer = XMLOutputFactory.newInstance().createXMLStreamWriter(
theXMLString);
new FeedWriter().writeEntries(writer, entries);
writer.flush();
writer.close();
assertEquals(theXMLString.toString(), entry2Result);
entries = new FeedReader(feedDoc).readEntry(XMLInputFactory
.newInstance().createXMLStreamReader(
new StringReader(entry3)), null);
assertTrue(entries != null);
assertTrue(entries.size() == 1);
theXMLString = new StringWriter();
writer = XMLOutputFactory.newInstance().createXMLStreamWriter(
theXMLString);
new FeedWriter().writeEntries(writer, entries);
writer.flush();
writer.close();
assertEquals(theXMLString.toString(), entry3Result);
entries = new FeedReader(feedDoc).readEntry(XMLInputFactory
.newInstance().createXMLStreamReader(
new StringReader(entry3Result)), null);
assertTrue(entries != null);
assertTrue(entries.size() == 1);
entries = new FeedReader(feedDoc).readEntry(XMLInputFactory
.newInstance().createXMLStreamReader(
new StringReader(entry4)), null);
assertTrue(entries != null);
assertTrue(entries.size() == 1);
theXMLString = new StringWriter();
writer = XMLOutputFactory.newInstance().createXMLStreamWriter(
theXMLString);
new FeedWriter().writeEntries(writer, entries);
writer.flush();
writer.close();
assertEquals(theXMLString.toString(), entry4Result);
try {