Forum Discussion

jorgeserrano's avatar
jorgeserrano
New Contributor
14 years ago

Soap Fault assertions fail when using soapUI Maven plugin

Hello,

I'm using SoapUI plugin for Maven and I've got an error in Schema Compliance assertion when response is a Soap Fault, and also fails Soap Fault assertion. The same test works OK when response is a normal Soap response, and it works OK for all responses (Soap Fault and normal responses) in SoapUI 3.6.1 application (not Maven plugin).

Can anyone help me know what might be happening?

The error I get is:


16:46:44,348 INFO [SoapUITestCaseRunner] Running soapUI testcase [getEmailDeUsuarioNotes TestCase]
16:46:44,348 INFO [SoapUITestCaseRunner] running step [peticionCorrecta]
16:46:44,959 INFO [SoapUITestCaseRunner] Assertion [Schema Compliance] has status VALID
16:46:44,959 INFO [SoapUITestCaseRunner] Assertion [SOAP Response] has status VALID
16:46:44,959 INFO [SoapUITestCaseRunner] Assertion [Not SOAP Fault] has status VALID
16:46:44,959 INFO [SoapUITestCaseRunner] running step [peticion con falloNormalizacion]
16:46:45,730 INFO [SoapUITestCaseRunner] Assertion [Schema Compliance] has status FAILED
16:46:45,730 ERROR [SoapUITestCaseRunner] ASSERTION FAILED -> Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/'; declare namespace flt='';declare namespace ns='http://ws.usuarios.servicios.sim.telvent.abengoa.com/';//env:Fault/flt:detail/ns:UsuarioNoEncontrado
16:46:45,730 INFO [SoapUITestCaseRunner] Assertion [SOAP Response] has status VALID
16:46:45,730 INFO [SoapUITestCaseRunner] Assertion [SOAP Fault] has status FAILED
16:46:45,730 ERROR [SoapUITestCaseRunner] ASSERTION FAILED -> Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/';//env:Fault
16:46:45,730 ERROR [SoapUITestCaseRunner] peticion con falloNormalizacion failed, exporting to [C:\apps\workspace\serviciodeusuariostest\TestSuite_01-getEmailDeUsuarioNotes_TestCase-peticion_con_falloNormalizacion-0-FAILED.txt]
16:46:45,750 INFO [SoapUITestCaseRunner] Finished running soapUI testcase [getEmailDeUsuarioNotes TestCase], time taken: 1378ms, status: FAILED

[...]

[ERROR] java.lang.Exception: Schema Compliance in [peticion con falloNormalizacion] failed;
[line -1: Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/'; declare namespace flt='';declare namespace ns='http://ws.usuarios.servicios.sim.telvent.abengoa.com/';//env:Fault/flt:detail/ns:UsuarioNoEncontrado]
Status: FAILED
Time Taken: 773
Size: 367
Timestamp: Tue Feb 01 16:46:44 CET 2011
TestStep: peticion con falloNormalizacion

----------------- Messages ------------------------------
[Schema Compliance] Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/'; declare namespace flt='';declare namespace ns='http://ws.usuarios.servicios.sim.telvent.abengoa.com/';//env:Fault/flt:detail/ns:UsuarioNoEncontrado
[SOAP Fault] Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/';//env:Fault

----------------- Properties ------------------------------
Encoding: UTF-8
Endpoint: http://srv-wasdes/servicio-de-usuarios/ws/ServicioDeUsuarios

---------------- Request ---------------------------
Request Headers: Host : srv-wasdes
Content-Length : 393
SOAPAction : ""
Accept-Encoding : gzip,deflate
User-Agent : Jakarta Commons-HttpClient/3.1
Content-Type : text/xml;charset=UTF-8


<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ws="http://ws.usuarios.servicios.sim.telvent.abengoa.com/">
<soapenv:Header/>
<soapenv:Body>
<ws:getEmailDeUsuarioNotes>
<!--Optional:-->
<usuarioNotes>Usuario</usuarioNotes>
</ws:getEmailDeUsuarioNotes>
</soapenv:Body>
</soapenv:Envelope>

---------------- Response --------------------------
Response Headers: Content-Language : es-ES
Transfer-Encoding : chunked
Date : Tue, 01 Feb 2011 15:46:45 GMT
#status# : HTTP/1.1 500 Internal Server Error
Content-Type : text/xml; charset=UTF-8
Connection : close
Server : IBM_HTTP_Server/6.1.0.19 Apache/2.0.47 (Win32)


<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Error normalizando usuario Usuario</faultstring>
<detail>
<ns1:NormalizedUser xmlns:ns1="http://ws.usuarios.servicios.sim.telvent.abengoa.com/"/>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>
SOAP Fault in [peticion con falloNormalizacion] failed;
[ Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/';//env:Fault]
Status: FAILED
Time Taken: 773
Size: 367
Timestamp: Tue Feb 01 16:46:44 CET 2011
TestStep: peticion con falloNormalizacion

3 Replies

  • s_nikhila's avatar
    s_nikhila
    Occasional Contributor
    Hello,

    In the above post you mentioned that SOAP fault assertions passed in SOAP UI 3.6.1. Did you run your test in test runner? Because I'm getting error for the SOAP fault responses and the test cases are getting failed due to time out. Only positive scenarios with corresponding assertions are passing.

    Please let me know how you executed the negative scenarios in test runner?

    Thanks in advance,
    Meenakshi
  • Hello, my error was caused by a failure in downloading maven dependencies, eviware maven repository sometimes gives errors. If you get timeout errors, have you tried to set a higher timeout in the TestRequest Properties tab?

    Regards,

    Jorge
  • I am facing same issue please anyone help me how to resolve this issue.

     

    [ Trying XBeans path engine... Trying XQRL... Trying delegated path engine... FAILED on declare namespace env='http://schemas.xmlsoap.org/soap/envelope/';//env:Fault]

     

    I have added xml beans and Saxon jar in my class path and added maximum response as well but still getting same issue.