cancel
Showing results for 
Search instead for 
Did you mean: 

Use of datasource to feed mockservice

Highlighted
New Contributor

Use of datasource to feed mockservice

Hello,

Is there a possibility to update the properties of a mockservice by using an excel file?

requestProperty1  requestProperty2
requestValue1          responseValue1
requestValue2          responseValue2

I want to use one single response message and have the returned values depend on the request. Preferably on the global MockService level so I can use them for all available services.

Thanks in advance!
Klaas-Jan Lute
4 REPLIES 4
Highlighted

Re: Use of datasource to feed mockservice

You will need to use Groovy for this.

You could save the parameters into the context in a Start script, and access them in the corresponding dispatch script.

I hope that helps.

/Nenad
http://eviware.com


 Join the virtual SmartBear Connect user conference on April 27-28! Get your free virtual ticket today!
Highlighted
New Contributor

Re: Use of datasource to feed mockservice

Hello Nenad,

Thank you very much for your reply. I have added the script and it works.

I know there are a lot of script fragments on the Eviware site and also on the internet. A developer was kind enough to help me out, but for a tester as me the proces of scripting is possibly a bit too complicated. It would be very nice to be able to add a datasource to a mockservice in the same way you do when working in a testsuite. Is it possible to add this to the wish list?

Kind regards,
Klaas-Jan
Highlighted

Re: Use of datasource to feed mockservice

Hi!

Definitely, it's on the list!

regards,

/Ole
eviware.com


 Join the virtual SmartBear Connect user conference on April 27-28! Get your free virtual ticket today!
Highlighted
New Contributor

Re: Use of datasource to feed mockservice

Great! Would be very useful.

Regards,
Klaas-Jan