Forum Discussion

tstmartin's avatar
tstmartin
Contributor
15 years ago

Test step "change operation" - how to change POST

Hi,

Is there a way to edit the http POST in soapUI Pro?

I have a single web service application which has about 20 bindings which are very similar.
Test cases are also very similar.
Would be great to be able to clone test steps and edit them to fit the different bindings.

I cloned a test step for a particular binding, then used the "change operation" dialog to change the operation.
The SOAP envelope changed as expected. However, when I issued the request, an error response was generated.

Looking at the request in RAW tab, I see that the http post wrapping the SOAP request was not changed; so the server is seeing a request URL for which the SOAP request is not defined, and of course generating an error.

Good request:
POST http ... blahblahblah/Xservice
<soapend ...blahblah
<methodInXservice> ....blablahblah

Bad Request after clone and "change operation" to Y service - note the http request has not changed:

POST http ... blahblahblah/Xservice
<soapend ...blahblah
<methodInYservice> ....blablahblah

1 Reply

  • Update -
    changing the Endpoint in the TestRequestProperties is the way to get the POST to change.
    However, this can be a little quirky.

    Also, the XML in the request may or may not change when the "change operation" is used -
    I haven't been able to find a fixed set of steps to repeat the problem, or to clear it.

    What I've found is that I can eventually make the new test step work, by a combination of saving the project, editing the request's XML in the XML tab, closing the test step interface and editing the Testrequest properties.

    I think the key is closing the test step's interface - I think this is acting like an editor that is cached and not completely refreshed when the underlying test request has changed.