Forum Discussion
redfish4ktc2
13 years agoSuper Contributor
Hi
I've just seen your post, maybe it is not to late for an answer
definitively yes, just stop the mock service, then restart it if neeeded
on response definition, you can add groovy script to make the service wait before providing the response
see this post for a static response time: viewtopic.php?f=5&t=20404#p46042
In your case, the script will need to access external resources where you store the information to make it increase/decrease this waiting time and so modify the behaviour of the mock service on the fly
The only drawback of this method is that you will need to configure all responses. But as you use soapui pro, you can put the script in an external file to avoid duplication
Maybe a better solution could be to put this on the "OnRequest script" tab (see http://www.soapui.org/Service-Mocking/c ... g-overview). In this case, no duplications
Check also this documentation: http://www.soapui.org/Service-Mocking/c ... vices.html
I've just seen your post, maybe it is not to late for an answer
be able to switch mock service on/off also on the fly to simulate failure of an interfaced system.
definitively yes, just stop the mock service, then restart it if neeeded
be able to change response time "on the fly" during the test run to simulate performance degradation of an interfaced system
on response definition, you can add groovy script to make the service wait before providing the response
see this post for a static response time: viewtopic.php?f=5&t=20404#p46042
In your case, the script will need to access external resources where you store the information to make it increase/decrease this waiting time and so modify the behaviour of the mock service on the fly
The only drawback of this method is that you will need to configure all responses. But as you use soapui pro, you can put the script in an external file to avoid duplication
Maybe a better solution could be to put this on the "OnRequest script" tab (see http://www.soapui.org/Service-Mocking/c ... g-overview). In this case, no duplications
Check also this documentation: http://www.soapui.org/Service-Mocking/c ... vices.html