/**
* Passes if the test does not throw any exceptions
*/
@Test
public void testWriterOptions() throws Exception {
Abdera abdera = new Abdera();
Entry entry = abdera.newEntry();
entry.setTitle("1");
ByteArrayOutputStream out = new ByteArrayOutputStream();
WriterOptions writeoptions = entry.getDefaultWriterOptions();
writeoptions.setCompressionCodecs(CompressionCodec.DEFLATE);
writeoptions.setCharset("UTF-16");
writeoptions.setAutoClose(true);
entry.getDocument().writeTo(out,writeoptions);
out.close();
byte[] bytes = out.toByteArray();
ByteArrayInputStream in = new ByteArrayInputStream(bytes);
Parser parser = abdera.getParser();
ParserOptions options = parser.getDefaultParserOptions();
options.setCompressionCodecs(CompressionCodec.DEFLATE);
Document<Entry> doc = abdera.getParser().parse(in,null,options);
doc.getRoot().toString();
}