Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mock web service

We have two components: enterprise application X, and Web service Y

We want to make our (automated) testing tool that will test application X (that interact with Y) only, and we have not the web service Y available.

Notes:

  • The testing tool will be a desktop application.

  • We Don't want to use another external tools-e.g. SoapUI- for testing (as we want to automate the testing by running one application).

The question is: How we can mock the web service Y in our testing -desktop- application? Does it is easy to mock it by Socket programming, or any other method/library?

Thanks in advance,

like image 658
Moro Avatar asked Feb 10 '10 09:02

Moro


People also ask

What is mock in web services?

A mock service is just a representation of a real web service. For that reason, it cannot be accurate to the maximum – it does not take into account the service specifics and may contain various bugs. The primary purpose of a mock service is testing, so this service usually lacks complexity of a live environment.

What is the use of mock service?

A Mock service is an important feature of the SoapUI testing tool. It creates a dummy or virtual web service that simulates a response to a web service request. The mocking service creates a virtual environment to test the web service that works similarly to real service.

Is Postman a MockServer?

Mock servers simulate an API by returning predefined data, enabling you to develop or test against an API before it's production-ready (or without using production data). In Postman, mock servers rely on examples saved in a collection to return mock data.


1 Answers

I found a solution in Java 6

web-services-without-ee-containers

thanks

like image 51
Moro Avatar answered Sep 20 '22 00:09

Moro