Forum Discussion

Target_MN_-_soa's avatar
Target_MN_-_soa
Occasional Contributor
14 years ago

Validation passes without element

I have an assertion to validate response and my xpath match assertion has following:

expected:

<?xml version="1.0" encoding="UTF-8"?>

And some other stuff

Actual:

And some other stuff

Result is that assertion passes without presence of "<?xml version="1.0" encoding="UTF-8"?>"

What could be the issue?

1 Reply

  • Hi,

    good catch - XML processing instructions are ignored by the XPath matching engine - I suggest you add a Contains assertion for the XML Header to make sure it is there also.

    regards,

    /Ole
    SmartBear Software