Forum Discussion

Yarnos's avatar
Yarnos
Occasional Contributor
8 years ago

POST request without PrepareRequestObject

I am fairly new to Web Service testing and have hit a problem. Would appreciate help or guidance please.

 

I want to POST a request to my webservice using TestComplete WebServices

 

If I use a Webservice checkpoint, it doesn't work sending my XML request as I need HTTP headers.

 

So I create a RequestXML using below

Set RequestXml = ServiceInfo.PrepareRequest(MethodName, RequestObj)

 

However the actual xml it produces is not the xml I want, and I cant change it within the object. (The method is complex)

So when I post the request the response is a fault code

 

Call XmlHttpRequest.open("POST", "http://url?wsdl", False)
Call XmlHttpRequest.setRequestHeader("Content-Type", "text/xml")
Call XmlHttpRequest.send(RequestXML)

 

Is there a way of creating a the RequestXML not based on an existing method or is there just an easier way to send the xml?

No RepliesBe the first to reply