Defining Test Steps - WinRunner

After you run a test, WinRunner displays the overall result of the test (pass/fail) in the Report form. To determine whether sections of a test pass or fail, add tl_step statements to the test script.

The tl_step function has the following syntax:

tl_step ( step_name, status, description );

The step_name is the name of the test step. The status determines whether the step passed (0), or failed (any value except 0). The description describes the step.

For example, in the following test script segment, WinRunner reads text from Notepad. The tl_step function is used to determine whether the correct text is read.

When the test run is complete, you can view the test results in the WinRunner Report. The report displays a result (pass/fail) for each step you defined with tl_step.

Note that if you are using TestDirector to plan and design tests, you should use tl_step to create test steps in your automated test scripts. For more information, refer to the TestDirector User’s Guide.


All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

WinRunner Topics