Site icon Tutorial

RESTful Mocking

RESTful Mocking

Let’s understand RESTful Mocking. The REST service mocking feature allows you to simulate a REST service by creating a mock service. You can then run it either directly from SoapUI, or use the mockservicerunner.bat command-line application.

Share and Distribute Mocks

If you need to share your mock service with other members of your team or even with partners and customers, you can easily save the mock you have created to a WAR file. You can then deploy this WAR mock service in any Java server environment – it will run even without SoapUI.

Create Scripts

You can enhance your mocks via scripts. Scripts allow you to simulate almost any behavior, including dynamic results, random errors, responses containing variables, and so on.

Sample REST Mock Service

In general, a mock service simulates a live service by exposing a certain number of mock actions. Mock actions, in turn, contain a quantity of mock responses.

Let us take a look at the sample mock service:

Make your resume stand out and become a Certified SoapUI Testing Professional. Try free practice tests here!

A great career is just a certification away. So, practice and validate your skills to become Certified SoapUI Testing Professional

Exit mobile version