Hi all,
I came across a strange one today, it goes like this:
I'm setting up test suites for QAing a web service of mine, which is written in PHP5 - making use of the class SoapFault among others.
I use the class to return error message to the clients. Example:
if (!$this->CheckHost(getenv('REMOTE_ADDR')))
{
return new SoapFault(S_CLIENT, S_STRING_IP, "", S_DETAIL_IP);
}
Returning a SoapFault if the client is not authorized...
Now, if I add an Schema Compliance assertion in soapUI 3.0.1 it tells me that the returned message is not compliant to it's wsdl file.
The WSDL-file is written by me and does in deed not contain a description of the actual SoapFault class. Would that be needed? Thought not because SoapFault is spezified in Soap 1.1 anyways.
The actual response looks like this:
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode>SOAP-ENV:Client</faultcode>
<faultstring>ERR_102</faultstring>
<faultactor/>
<detail>IP error message</detail>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
The soapUI error message is:
Element 'detail' with element-only content type cannot have text content.
Does anyone have a hint what I'm doing wrong?
tia
K