Examples of ScriptMockOperationDispatcher


Examples of com.eviware.soapui.impl.wsdl.mock.dispatch.ScriptMockOperationDispatcher

    @Test
    public void testResponsesAreDispatchedWithScript() throws Exception {
        mockAction.addNewMockResponse("response 2");

        mockAction.setDispatcher(new ScriptMockOperationDispatcher(mockAction));
        mockAction.setScript("return 'response 2'");

        RestMockResult mockResult = mockAction.dispatchRequest(restMockRequest);
        assertThat(mockResult.getMockResponse().getName(), is("response 2"));
View Full Code Here

Examples of com.eviware.soapui.impl.wsdl.mock.dispatch.ScriptMockOperationDispatcher

    @Test
    public void testResponsesScriptDispatchingHasDefaultResponse() throws Exception {
        mockAction.addNewMockResponse("response 2");

        mockAction.setDispatcher(new ScriptMockOperationDispatcher(mockAction));
        mockAction.setDefaultResponse("response 2");
        mockAction.setScript("return 'absent response'");

        RestMockResult mockResult = mockAction.dispatchRequest(restMockRequest);
        assertThat(mockResult.getMockResponse().getName(), is("response 2"));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.