// Issuer
assertEquals("http://localhost:8080/sales/", lotRequest.getIssuer().getValue());
// Try out writing
ByteArrayOutputStream baos = new ByteArrayOutputStream();
SAMLRequestWriter writer = new SAMLRequestWriter(StaxUtil.getXMLStreamWriter(baos));
writer.write(lotRequest);
ByteArrayInputStream bis = new ByteArrayInputStream(baos.toByteArray());
DocumentUtil.getDocument(bis); // throws exceptions
baos = new ByteArrayOutputStream();
// Lets do the writing
writer = new SAMLRequestWriter(StaxUtil.getXMLStreamWriter(baos));
writer.write(lotRequest);
String writtenString = new String(baos.toByteArray());
Logger.getLogger(SAMLSloRequestParserTestCase.class).debug(writtenString);
validateSchema(writtenString);
}