14 years ago
dispatch different response for external client request
I'm attempting to intercept an external client request and have the mockservice send back a different response accordingly e.g. request name =1 --> response 1, request name 2 = response 2. I can get the request values to be intercepted within the soapui application but *not* from an external client.
I have tried script and query_match. What have I done incorrectly, can't I use the dispatch framework for external clients? the holder["//UserLogin"] is blank for external requests
e.g.
I have tried script and query_match. What have I done incorrectly, can't I use the dispatch framework for external clients? the holder["//UserLogin"] is blank for external requests
e.g.
// create XmlHolder for request content
def holder = new com.eviware.soapui.support.XmlHolder( mockRequest.requestContent )
// get arguments
def arg1 = holder["//UserLogin"]
log.info"value is [$arg1]"
log.info"**************************************************************"
if( r == 2 )
return "false"
//for other values return another response.