Forum Discussion
AlexKaras
12 years agoCommunity Hero
Hi Siddharth,
You are probably mixing two headers here...
The case is that the Response parameter of the OnWebServiceResponse() method contains the contents of http response body, but not the http header.
This response body contains SOAP response from the web service and this response is an xml document with the Envelope root element. Envelope must contain Body child and may contain Header child.
This is what you've seen in TestComplete.
What you posted as Fiddler's output was the contents of http header and this header should be processed by TestComplete internally. If http response contains a cookie, I believe that this cookie should be handled internally by TestComplete.
I believe that SmartBear's Support will comment if I am wrong here.
So I would advise to try to work with your web service using regular TestComplete's Web Service testing means and check if this can be done.
If it appears that for some reason TestComplete does not handle cookies as required (this can be checked using Fiddler), I am afraid that you will have to build requests to web service manually.
These threads might help to learn how to do this:
http://smartbear.com/forums/f81/fp2/t75732/testcomplete-web-service-communication/
http://kapie.com/2007/consuming-soap-web-services-from-vbscript
http://social.msdn.microsoft.com/Forums/en-US/4f00c08e-0188-48ac-9bd8-78607c8fbfb9/call-a-web-service-from-client-vbscript?forum=asmxandxml
You are probably mixing two headers here...
The case is that the Response parameter of the OnWebServiceResponse() method contains the contents of http response body, but not the http header.
This response body contains SOAP response from the web service and this response is an xml document with the Envelope root element. Envelope must contain Body child and may contain Header child.
This is what you've seen in TestComplete.
What you posted as Fiddler's output was the contents of http header and this header should be processed by TestComplete internally. If http response contains a cookie, I believe that this cookie should be handled internally by TestComplete.
I believe that SmartBear's Support will comment if I am wrong here.
So I would advise to try to work with your web service using regular TestComplete's Web Service testing means and check if this can be done.
If it appears that for some reason TestComplete does not handle cookies as required (this can be checked using Fiddler), I am afraid that you will have to build requests to web service manually.
These threads might help to learn how to do this:
http://smartbear.com/forums/f81/fp2/t75732/testcomplete-web-service-communication/
http://kapie.com/2007/consuming-soap-web-services-from-vbscript
http://social.msdn.microsoft.com/Forums/en-US/4f00c08e-0188-48ac-9bd8-78607c8fbfb9/call-a-web-service-from-client-vbscript?forum=asmxandxml