Interview Questions

How to Invoking a MockService ?

SoapUI FAQ


(Continued from previous question...)

How to Invoking a MockService ?

1. First we must start the MockService. Click the Start button in the MockService editor, run, this will start the service on the configured port and path. To the Top Right of the Editor you should see that it's running, and the port it's responding on. The play Button is greyed out and if you would like to stop the MockService, just click the stop button.
2. In the MockResponse editor, Click the Button Create Request.
3. This will prompt you to to open one of the existing requests for its operation in your project.
4. You will also need to give it a name
5. When you open the request, SoapUI will automatically change its endpoint to the endpoint of the locally running MockService instead of the endpoint that the WSDL is using. Submit the opened request by clicking the Run Button.
6. If you switch back to the MockResponse editor and select its Incoming Request view, you should be able to see the request that was posted to the MockService and handled by the MockOperation.

(Continued on next question...)

Other Interview Questions