You can create a property value synchronization point, which instructs WinRunner to wait for a specified property value to appear in a GUI object. For example, you can tell WinRunner to wait for a button to become enabled or for an item to be selected from a list.
The method for synchronizing a test is identical for property values of objects and windows. You start by choosing Insert > Synchronization Point > For Object/Window Property. As you pass the mouse pointer over your application, objects and windows flash. To select a window, you click the title bar or the menu bar of the desired window. To select an object, you click the object.
A dialog box opens containing the name of the selected window or object. You can specify which property of the window or object to check, the expected value of that property, and the amount of time that WinRunner waits at the synchronization point.
A statement with one of the following functions is added to the test script, depending on which GUI object you selected:
During a test run, WinRunner suspends the test run until the specified property value in a GUI object is detected. It then compares the current value of the specified property with its expected value. If the property values match, then WinRunner continues the test.
In the event that the specified property value of the GUI object does not appear, WinRunner displays an error message, when the mismatch_break testing option is on. For information about the mismatch_break testing option, see “Setting Testing Options from a Test Script.” You can also set this testing option globally using the corresponding Break when verification fails option in the Run > Settings category of the General Options dialog box.
If the window or object you capture has a name that varies from run to run, you can define a regular expression in its physical description in the GUI map. This instructs WinRunner to ignore all or part of the name.
During recording, when you capture an object in a window other than the active window, WinRunner automatically generates a set_window statement.
To insert a property value synchronization point:
The dialog box closes and a _wait_info statement that checks the property values of an object is inserted into your test script. For example, button_wait_info has the following syntax:
button_wait_info ( button, property, valuetime );
The button is the name of the button. The property is any property that is used by the button object class. The value is the value that must appear before the test run can continue. The time is the maximum number of seconds WinRunner should wait at the synchronization point, added to the timeout_msec testing option.
For example, suppose that while testing the Flight Reservation application you order a plane ticket by typing in passenger and flight information and clicking Insert. The application takes a few seconds to process the order. Once the operation is completed, you click Delete to delete the order.
In order for the test to run smoothly, a button_wait_info statement is needed in the test script. This function tells WinRunner to wait up to 10 seconds (plus the timeout interval) for the Delete button to become enabled. This ensures that the test does not attempt to delete the order while the application is still processing it. The following is a segment of the test script:button_press ("Insert");
WinRunner Related Interview Questions
|SILK TEST Interview Questions||LoadRunner Interview Questions|
|WinRunner Interview Questions||HTML Interview Questions|
|QTP Interview Questions||Manual Testing Interview Questions|
|OpenStack Interview Questions||Automation Testing Interview Questions|
|API testing Interview Questions||Rational robot Interview Questions|
|Selenium IDE Interview Questions||Performance Testing Interview Questions|
|Test Director Interview Questions|
Winrunner At A Glance
Understanding How Winrunner Identifies Gui Objects
Understanding Basic Gui Map Concepts
Working In The Global Gui Map File Mode
Editing The Gui Map
Merging Gui Map Files
Configuring The Gui Map
Learning Virtual Objects
Checking Gui Objects
Working In The Gui Map File Per Test Mode
Working With Web Objects
Working With Activex And Visual Basic Controls
Checking Powerbuilder Applications
Checking Table Contents
Creating Data-driven Tests
Synchronizing The Test Run
Defining And Using Recovery Scenarios
Handling Web Exceptions
Using Regular Expressions
Enhancing Your Test Scripts With Programming
Creating User-defined Functions
Creating Compiled Modules
Calling Functions From External Libraries
Creating Dialog Boxes For Interactive Input
Understanding Test Runs
Analyzing Test Results
Running Batch Tests
Running Tests From The Command Line
Controlling Your Test Run
Setting Properties For A Single Test
Setting Global Testing Options
Customizing The Test Script Editor
Customizing The Winrunner User Interface
Setting Testing Options From A Test Script
Customizing The Function Generator
Initializing Special Configurations
Integrating With Quicktest Professional
Managing The Testing Process
Testing Systems Under Load
All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd
Wisdomjobs.com is one of the best job search sites in India.