bhelm
15 years agoNew Contributor
Failed to find Mock Response from SoapUI 3.6.1 w/QUERY_MATCH
I had a mock operation with only one response and dispatch type Sequence. I added some error mock responses to the mock operation and corresponding queries for each, with the default response being the original only response. Now none of the responses are being returned; instead, I get the fault below. Can anybody give me a clue what I have messed up?
javax.xml.ws.soap.SOAPFaultException: Response was of unexpected text/html ContentType. Incoming portion of HTML stream: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>Server</faultcode>
<faultstring>Failed to find MockResponse</faultstring>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>Server</faultcode>
<faultstring/>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
Another clue: soap-errors.log shows this NullPointerException:
2011-01-28 17:18:22,100 ERROR [errorlog] java.lang.NullPointerException
java.lang.NullPointerException
at com.eviware.soapui.tools.SoapUIMockServiceRunner$LogListener.onMockResult(SoapUIMockServiceRunner.java:230)
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:405)
...
What could I have made null that should not be?
One further question, why is the content type text/html for XML output? I expect SoapUI to ALWAYS output text/xml.
javax.xml.ws.soap.SOAPFaultException: Response was of unexpected text/html ContentType. Incoming portion of HTML stream: <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>Server</faultcode>
<faultstring>Failed to find MockResponse</faultstring>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>Server</faultcode>
<faultstring/>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
Another clue: soap-errors.log shows this NullPointerException:
2011-01-28 17:18:22,100 ERROR [errorlog] java.lang.NullPointerException
java.lang.NullPointerException
at com.eviware.soapui.tools.SoapUIMockServiceRunner$LogListener.onMockResult(SoapUIMockServiceRunner.java:230)
at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:405)
...
What could I have made null that should not be?
One further question, why is the content type text/html for XML output? I expect SoapUI to ALWAYS output text/xml.