Search in sources :

Example 6 with DynamicClientFactory

use of org.apache.cxf.endpoint.dynamic.DynamicClientFactory in project cxf by apache.

the class ClientServerPartialWsdlTest method testCXF4676partial2.

@Test
public void testCXF4676partial2() throws Exception {
    DynamicClientFactory dcf = DynamicClientFactory.newInstance();
    Client client = dcf.createClient("http://localhost:" + PORT + "/AddNumbersImplPartial2Service?wsdl", serviceName2, portName2);
    updateAddressPort(client, PORT);
    Object[] result = client.invoke("addTwoNumbers", 10, 20);
    assertNotNull("no response received from service", result);
    assertEquals(30, result[0]);
}
Also used : DynamicClientFactory(org.apache.cxf.endpoint.dynamic.DynamicClientFactory) Client(org.apache.cxf.endpoint.Client) Test(org.junit.Test)

Aggregations

Client (org.apache.cxf.endpoint.Client)6 DynamicClientFactory (org.apache.cxf.endpoint.dynamic.DynamicClientFactory)6 Test (org.junit.Test)5 URL (java.net.URL)3 SOAPServiceBogusAddressTest (org.apache.hello_world_soap_http.SOAPServiceBogusAddressTest)2 SOAPServiceMultiPortTypeTest (org.apache.hello_world_soap_http.SOAPServiceMultiPortTypeTest)2 Method (java.lang.reflect.Method)1 Bus (org.apache.cxf.Bus)1 CXFBusFactory (org.apache.cxf.bus.CXFBusFactory)1 LoggingFeature (org.apache.cxf.ext.logging.LoggingFeature)1