use of com.predic8.membrane.core.interceptor.ws_addressing.DecoupledEndpointRegistry in project service-proxy by membrane.
the class WsaEndpointRewriterTest method testRewriteEndpointAddress.
@Test
public void testRewriteEndpointAddress() throws XMLStreamException {
ByteArrayOutputStream output = new ByteArrayOutputStream();
WsaEndpointRewriter rewriter = new WsaEndpointRewriter(new DecoupledEndpointRegistry());
int port = 2000;
rewriter.rewriteEndpoint(input, output, port, new Exchange(null));
String rewrittenXml = output.toString();
System.out.println(rewrittenXml);
assertTrue(rewrittenXml.contains("<Address>http://localhost:" + port + "/decoupled_endpoint</Address>"));
}
Aggregations