free seo tool

Mock Service in soapUI with Example

soapUI provides a great feature called MockService for testing web services. This is really helpful for a tester if he plans to automate the web services testing. By using the MockService feature, one can start working on soapUI automation script just with the WSDLs. In other words, the web service doesn't have to be connected to a web server or a back end database server to start the automation. 
MockService mimics the behavior of a server and send the response back to soapUI as if it is coming from a server. Let us see an example below.

You can create a mock service while creating a project or you can right click on the interface and select create Mock Service at any point. See the below image.
In this case we have selected two services "CelsiusToFahrenheit" and "FahrenheitToCelsius" for creating a mock service. Checking the "Add Endpoint" will add the end point to the request in the test case. After creation of this mock service, your local machine will act as a server hosting these two web services and you can access those services by using the end point of the mock service. Once you have the mock service created, double click on the Response of each method and specify value for all the elements in the response. This way once you hit the end point, you will have some data returned from the mock service. During the initial stages of development, you might ask the development team to provide just the WSDL and you can create MockService using the WSDL and start working on your soapUI automation scripts.
4 comments:
  • Anonymous says:
    September 16, 2012

    I've read some good stuff here. Definitely price bookmarking for revisiting. I surprise how much effort you place to make this kind of fantastic informative website.
    my web page > free senuke Xcr

  • Unknown says:
    March 15, 2014

    In other words, the web service doesn't have to be connected to a web server or a back end database server to start the automation. Senuke Services

  • Eliaz Beth says:
    April 14, 2014

    Likes substantially boost the acceptance within your respective internet site and with the appropriate selection count; a lot of people will be drawn to your account. The companies that offer these professional companies, ig likes will offer you with non-automated or robotic likes and provide you with genuine Instagram likes. The good element regarding this is usually that these are generally quickly shipped for your account in order that you would not have to wait that quite a bit. And when you are a compact company, escalating your Instagram likes could be beneficial.

  • Unknown says:
    October 07, 2016

    very nice article

Post a Comment

This is a new website mainly for SOA Testers using soapUI. Let me know your thoughts/ suggestions.