Posted by: devakara on: October 8, 2008
Property transfers become crucial steps in scenarios where validations are done mostly using derived data.
Lets say after some Groovy script execution we end up setting a property value in Properties step while testing an application’s functionality. And most of the times we would be in need of the obtained result out of that groovy step. As we have it in Properties Step we can access it using Property Expansion technique and also using Property Transfer Step.
Property Transfer Step shall be in between the Properties Step and SOAP request Step, but before placing the Transfer Step have Properties and SOAP request Steps in place. Property Transfer window would something like this:
After creating a new Property Transfer in the above window say ‘RefNumTransfer‘, select source, in this case it would be the ‘Properties’ Step, this inturn provides the list of all properties defined under that Step, select the property you wish to transfer.
Now come to Target block, where we would have our SOAP request to catch the property transfer. Initially declare all the namespaces that your request would use, separating each of them with ‘;’ and then provide the XPath of the target node which should capture the transfered value.
For example if the SOAP request as is below
then the target block of Property Transfer should contain details like this:
Try running the Property Transfer step, you see the ‘Transfer Name’ and ‘Transfered Value’ in the Transfer Log, and also correspondingly that value is reflected in the SOAP request at the target XPath.
Hi,
i wanted to know if proeprty transfer can be done across the test cases. because what i have found that if you want to transfer the prop. you can do that to only a step in teh same tase case . but what if i have two cases in test suit and want to use the response of 1st in 2nd … i tried that but when you create a transfer prop. in teh target you can only see the items related to that test case and not the next case . please correct me if i am wrong
Hi,
As mentioned above in Property Transfer in SOAPUI, same i did for request, I am sending to my webservice, which results the value transferrred in request xml(test step) and Removes all code inside the request that is all tags and also removes the question mark (? where in I was expecting the value to be filled).
then If i run the test it failed, Please suggest
October 15, 2008 at 8:36 am
Thank you