Forum Discussion
Hi Rao,
Unfortunately, these are not the droids we are looking for :(
The link you posted describes handling the request from the MockService side. If this was possible in our environment, it would be quite easy, as the MockService provides the 'mockRequest' object directly available in the OnRequest.
There are several reasons why we cannot handle requests from the mockservice:
- the mockservice is not being triggered as a part of the TestCase, it's running independently
- we don't know which test step will require to access the request's content, so we cannot inject it into a TestCase context from within the OnRequest Script of the MockService
- we cannot create a DB which would hold the requests and responses, as it's deployed on the customer's system
I've managed to access the context object of the MockService from within a TestStep script and while this wouls allow me to save each request into the context, it's not a good solution, as the context would grow really big with a large amount of requests.
In short, I need to access the Request content on a MockService from within a TestStep Script, not from the OnRequest Script of the MockService.
Jakub
- Siemens__s_r_o_10 years agoOccasional Contributor
Actually, it seems I'm trying to to somthing very similar to larsn
here(link doesn't seem to be working, see the post in the old forums), but the link provided there doesnt help, as it deals with the MessageExchage object in context of an assertion script.//edit with a link to old forums
- Siemens__s_r_o_10 years agoOccasional Contributor
Bump.
(I don't know, are bumps ok? :) )
Related Content
- 5 years agojlarsen
- 8 years agominoseah629