SOAP Webservice Testing

Importing WSDL from Salesforce into Provar

To test a Salesforce Web Service you need the corresponding WSDL. For more information on WSDLs click here. Do the following to locate the WSDL for the web service you would like to call. Login to Salesforce. Choose Setup > Develop > Apex Classes. Locate the Apex Class and right click on the WSDL link. Choose ‘Save link as’. Save this file in the /WSDL directory (you may need to create this directory in Provar).


Creating Test Case with SOAP Webservice API

Firstly you require a Salesforce connection to your testcase.  You can drag this from the Org Browser.
Add Web Service Request API to your TestCase by dragging it from the Test API view.

Select the WSDL document using the File selection editor. Choose the Service, Port and Operation by selecting the from the drop down menus. Select the magic wand to generate sample XML. You can use Variables in the Body Contents by choosing spacebar in the usual way. If you execute the test in Debug you can inspect the return object (WebResponse) using the Variables view.


Leave A Comment