When you have access to the response from an HTTP-based step, you can use the response to add an assertion directly.
This example of the HTTP/HTML response uses the login step in the multi-tier-combo test case. The point of this example is to test whether the text "MyMoney Home" appears in the response.
Follow these steps:
In this example, the assertion fires if the text "MyMoney Home" is not present, and then redirects to the fail step.
The assertion that was generated appears in the login step.
Running one Filter and one Assertion
Alternatively, if you wanted a filter to capture the value "MyMoney Home," and run it as an assertion, use the Parse Value filter.
The HTML/XML Filter Info window shows that the Property Key value is the filter to apply and Expression is the assertion to fire.
As a result, one filter and one assertion are added to the login step and appear n in the model editor.
Note: The same assertion capabilities are available when an HTML response is displayed in the step editor.
Copyright © 2014 CA Technologies.
All rights reserved.
|
|