5

I am using SoapUI 2.5.1 - evaluation version

In a testcase, how to save the response messages along with requests in a SoapUI project ?

Here is what is happening currently: When I create a Web service SoapUI project and send SOAP request for an operation, I get a response XML. Now after saving the soapUI and exiting the tool - when I open it again I see the response XML tab as empty. alt text

Why only request gets saved and not responses - Is it a bug in SoapUI ?

Thanks -Arun

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
akjain
  • 1,787
  • 3
  • 20
  • 35

2 Answers2

6

As Thomas Bratt indicates, the response is not saved because in most cases, it doesn't make sense to do so. SoapUI is intended for testing; if you want to save your test results, you'll have to do that explicitly.

To save a specific response message, use the context menu of the response editor, (or press Ctrl+S), and save it to file. You can load it back if you want, using the same context menu (or press Ctrl+L).

Martijn
  • 13,225
  • 3
  • 48
  • 58
  • 1
    Thanks Thomas and Martijn for pointing out why its not meaningful for the tool to save responses. – akjain May 20 '09 at 14:59
  • Totally agree with @akjain - What's so terrible about it ? If you use "Postman" then there is button/link "save response" and it saves tests in history with all results. Property "dump file" is read only. Ctrl+S saves whole project, not response. It's not the same. Oh but you can write your own script, how boring: https://community.smartbear.com/t5/API-Functional-Security-Testing/Saving-request-and-response/td-p/171405 – Peter Feb 16 '21 at 15:54
  • @Peter Pressing Ctrl+S in the response editor will just save the response, **not** the entire project. – Martijn Mar 03 '21 at 19:48
4

The response is not saved because it may vary between calls.

I think the logic is that only the requests need to be saved. The responses are generated by the server automatically each time.

For example, a 'get time' SOAP method would return a different result each time. I use SOAP-UI at work for communicating with a SOAP server that brokers video connection requests and returns an error code. The error code is different each time so it does not make sense to save it.

You can use the context menu of the request to create a test case. This will let you check the response against the WSDL schema and also assert that the response does not contain a SOAP fault.

Thomas Bratt
  • 48,038
  • 36
  • 121
  • 139