new QName("http://apache.org/hello_world/services",
"SoapPort");
@Test
public void testWSDLPublishWithCatalogs() throws Exception {
Endpoint ep = Endpoint.publish(null, new GreeterImpl());
try {
URL url = new URL("http://localhost:9000/SoapContext/SoapPort?"
+ "xsd=testutils/hello_world_schema2.xsd");
assertNotNull(url.getContent());
url = new URL("http://localhost:9000/SoapContext/SoapPort"
+ "?xsd=testutils/hello_world_schema.xsd");
String result = IOUtils.toString((InputStream)url.getContent());
assertTrue(result.contains("xsd=testutils/hello_world_schema2.xsd"));
url = new URL("http://localhost:9000/SoapContext/SoapPort"
+ "?wsdl=testutils/hello_world_messages_catalog.wsdl");
result = IOUtils.toString((InputStream)url.getContent());
assertTrue(result.contains("xsd=testutils/hello_world_schema.xsd"));
} finally {
ep.stop();
}
}