SOAP request Assertions using Cheerio

Hi @bpricilla,

Thanks for the details! I can’t seem to get the same response that you have, given the information provided. I receive a 415 Unsupported Media Type Error, refer to the screenshot below:

However, since you provided the response body, I was able to test against it by defining a static variable to contain the xml.

After enough testing, I was able to figure it out. To get value you are looking for, try this:

$('m\\:NumberToWordsResponse').attr('xmlns:m')

That should get you the text value of the xmlns:m attribute.

And applying it in a test as you have seemed to work as well.

I hope this helps!

Orest

1 Like