public void testContextOutput()
throws Exception
{
System.out.println("Running test : " + this.getClass().getName());
UserCoordinator ua = UserCoordinatorFactory.userCoordinator();
try
{
ua.begin();
System.out.println("Started: "+ua.identifier()+"\n");
DeploymentContext manager = DeploymentContextFactory.deploymentContext();
Context theContext = manager.context();
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
DocumentBuilder builder = factory.newDocumentBuilder();
org.w3c.dom.Document doc = builder.newDocument();
org.w3c.dom.Element root = doc.createElement("Context-test");
// this fails because the documents are different -- need a better test than this
((SOAPContext)theContext).serialiseToElement(root) ;
doc.appendChild(root);
// this does not do a full recursive conversion to text format -- need a better test than this
System.out.println(com.arjuna.mw.wscf.utils.DomUtil.nodeAsString(doc));
ua.cancel();
}
catch (Exception ex)
{
WSCFTestUtils.cleanup(ua);