Trailing white spaces are being removed from the request body.

Charu_TanejaCharu_Taneja Posts: 8

Hi,

I have a request body with trailing white spaces which are removed when the test is run. The response received for this request is successful. When i use the same recorded file to create virtual asset and run my tests through SOAtest, it works fine.
However, when the same test is run through CTP using this virtual asset i get Error in Event Logs since the request body does not match. The request body in recorded file does not have trailing white spaces and the request body received from service has trailing white spaces. This results in correlation error.

I have attached the problem statement.

Is there a solution to handle these trailing white spaces in request body?

Comments

  • Matt LoveMatt Love Posts: 36 admin

    Hi @Charu_Taneja

    Try switching the SOAP Client in the SOAtest test from Form Input to Literal XML and then add the trailing whitespace in the request body. The whitespace should be preserved in Literal XML request mode.

  • Charu_TanejaCharu_Taneja Posts: 8

    Thank you @Matt Love . I tried preserving the whitespaces in Literal XML request mode and it worked.

Sign In or Register to comment.