Package org.apache.cxf.systest.ws.addr_feature

Examples of org.apache.cxf.systest.ws.addr_feature.AddNumbersService


    private AddNumbersService getService() {
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);

        AddNumbersService service = new AddNumbersService(wsdl, serviceName);
        assertNotNull("Service is null ", service);
        return service;
    }
View Full Code Here


        ByteArrayOutputStream input = setupInLogging();
        ByteArrayOutputStream output = setupOutLogging();
       
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);
        AddNumbersService service = new AddNumbersService(wsdl, serviceName);


        Dispatch<Source> disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                                       Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:" + PORT + "/jaxws/add");

        disp.invoke(new StreamSource(new StringReader(req)));
       
       
        assertLogContains(output.toString(), "//wsa:Action", base + "addNumbersRequest");
        assertLogContains(input.toString(), "//wsa:Action", base + "addNumbersResponse");
       

        output.reset();
        input.reset();
       
        disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                      Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:" + PORT + "/jaxws/add");
       
View Full Code Here

        //String base = "http://apache.org/cxf/systest/ws/addr_feature/AddNumbersPortType/";
        String expectedOut = "http://bad.action";
       
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);
        AddNumbersService service = new AddNumbersService(wsdl, serviceName);


        Dispatch<Source> disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                                       Source.class, Mode.MESSAGE);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:" + PORT + "/jaxws/add");
View Full Code Here

    private AddNumbersPortType getPort() {
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);

        AddNumbersService service = new AddNumbersService(wsdl, serviceName);
        assertNotNull("Service is null ", service);
        return service.getAddNumbersPort();
    }
View Full Code Here

        ByteArrayOutputStream input = setupInLogging();
        ByteArrayOutputStream output = setupOutLogging();
       
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);
        AddNumbersService service = new AddNumbersService(wsdl, serviceName);


        Dispatch<Source> disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                                       Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:9094/jaxws/add");

        //manually set the action
        disp.getRequestContext().put(BindingProvider.SOAPACTION_URI_PROPERTY,
                                     expectedOut);
        disp.invoke(new StreamSource(new StringReader(req)));
       
        assertTrue(output.toString().indexOf(expectedOut) != -1);
        assertTrue(input.toString().indexOf(expectedIn) != -1);
       

        output.reset();
        input.reset();
       
        disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                      Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:9094/jaxws/add");
       
View Full Code Here

    private AddNumbersPortType getPort() {
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);

        AddNumbersService service = new AddNumbersService(wsdl, serviceName);
        assertNotNull("Service is null ", service);
        return service.getAddNumbersPort();
    }
View Full Code Here

        ByteArrayOutputStream input = setupInLogging();
        ByteArrayOutputStream output = setupOutLogging();
       
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);
        AddNumbersService service = new AddNumbersService(wsdl, serviceName);


        Dispatch<Source> disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                                       Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:9094/jaxws/add");

        //manually set the action
        disp.getRequestContext().put(BindingProvider.SOAPACTION_URI_PROPERTY,
                                     expectedOut);
        disp.invoke(new StreamSource(new StringReader(req)));
       
        assertTrue(output.toString().indexOf(expectedOut) != -1);
        assertTrue(input.toString().indexOf(expectedIn) != -1);
       

        output.reset();
        input.reset();
       
        disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                      Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:9094/jaxws/add");
       
View Full Code Here

    private AddNumbersPortType getPort() {
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);

        AddNumbersService service = new AddNumbersService(wsdl, serviceName);
        assertNotNull("Service is null ", service);
        return service.getAddNumbersPort();
    }
View Full Code Here

    private AddNumbersPortType getPort() {
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);

        AddNumbersService service = new AddNumbersService(wsdl, serviceName);
        assertNotNull("Service is null ", service);
        return service.getAddNumbersPort();
    }
View Full Code Here

        ByteArrayOutputStream input = setupInLogging();
        ByteArrayOutputStream output = setupOutLogging();
       
        URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl");
        assertNotNull("WSDL is null", wsdl);
        AddNumbersService service = new AddNumbersService(wsdl, serviceName);


        Dispatch<Source> disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                                       Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:" + PORT + "/jaxws/add");

        //manually set the action
        disp.getRequestContext().put(BindingProvider.SOAPACTION_URI_PROPERTY,
                                     expectedOut);
        disp.invoke(new StreamSource(new StringReader(req)));
       
        assertTrue(output.toString().indexOf(expectedOut) != -1);
        assertTrue(input.toString().indexOf(expectedIn) != -1);
       

        output.reset();
        input.reset();
       
        disp = service.createDispatch(AddNumbersService.AddNumbersPort,
                                      Source.class, Mode.PAYLOAD);

        disp.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
                                     "http://localhost:" + PORT + "/jaxws/add");
       
View Full Code Here

TOP

Related Classes of org.apache.cxf.systest.ws.addr_feature.AddNumbersService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.