* 'org.apache.lucene.gdata.gom.core.GOMGeneratorImpl.writeAtomOutput(GOMWriter)'
*/
public void testWriteAtomOutput() throws XMLStreamException {
{
StringWriter stW = new StringWriter();
GOMOutputWriter writer = new GOMStaxWriter(stW);
this.impl.writeAtomOutput(writer);
assertEquals("<" + this.impl.getLocalName() + "/>", stW.toString());
}
{
StringWriter stW = new StringWriter();
GOMOutputWriter writer = new GOMStaxWriter(stW);
this.impl.setTextValue("Lucene");
this.impl.writeAtomOutput(writer);
assertEquals("<" + this.impl.getLocalName() + ">Lucene</"
+ this.impl.getLocalName() + ">", stW.toString());
}
{
StringWriter stW = new StringWriter();
GOMOutputWriter writer = new GOMStaxWriter(stW);
this.impl.setUri("http://apache.org");
this.impl.writeAtomOutput(writer);
assertEquals("<" + this.impl.getLocalName()
+ " uri=\"http://apache.org\">Lucene</"
+ this.impl.getLocalName() + ">", stW.toString());
}
{
StringWriter stW = new StringWriter();
GOMOutputWriter writer = new GOMStaxWriter(stW);
this.impl.setGeneratorVersion("1");
this.impl.writeAtomOutput(writer);
assertEquals("<" + this.impl.getLocalName()
+ " uri=\"http://apache.org\" version=\"1\">Lucene</"
+ this.impl.getLocalName() + ">", stW.toString());