Micro Focus QTP (UFT) Forums

Full Version: Validating XML from browser request
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi -

I'm recording an action on an HTML page. It's a form where I attempt to download a document. I fill in document name and click 'submit'.

The page refreshes and returns XML. I'd like to automatically validate the response but don't know how.

The response looks like this:

Code:
<status>
  <statusCode>-1</statusCode>
  <statusMessage>OK</statusMessage>
  <rootCauseMessage>You need to be logged in to access this functionality</rootCauseMessage>
  </status>

I'm using QTP 11. I have my action and then two items in it:

1. The Browser. It has the docName and the submit items.
2. The Browser. It waits for the browser to complete the current navigation.

I've attached an image of my workspace.

I'm a real newbie and just figuring things out. I'm guessing I should use an XML checkpoint but the videos I've seen don't go into much detail.

Can anyone please point me in the right direction?

Thank you for any helpful tips.