UIA Pro Add-in
Relevant for: GUI tests and components
This topic describes how to use UIA Pro to test applications that implement Microsoft UI Automation patterns. You can use UIA Pro to identify objects in your application when OpenText Functional Testing's normal object identification support is not sufficient for your needs.
Using UIA Pro requires the UIA Pro add-in to be installed and loaded.
An enhanced version of this add-in is available as a Beta offering. To use this version, you must specifically activate it.
Spy on objects in UIA Pro mode
The Object Spy and Object Identification Center provide a separate mode for UIA Pro object identification. Use this mode to identify objects based on their UI Automation properties and create UIA Pro test objects.
To spy on objects in UIA Pro mode
Do one of the following:
-
In the Object Spy, click the
pointing hand drop-down arrow, select UIA Pro, and click the
button to spy on an object in UIA Pro mode.
-
In the Object Identification Center, click the UIA Pro button to spy on objects in UIA Pro mode.
In the UIA Pro mode, you can view object properties, add the spied object to your local or shared repository, or drag it into your test to create a step. For details, see Use the Object Spy and Use the Object Identification Center.
Object properties are displayed as they would be recognized using UI Automation instead of their native technology.
Create UIAPro test steps
You can create objects and add them to your test from the Object Spy or Object Identification Center.
Each test object supports the following types of methods:
-
OpenText Functional Testing common methods and properties
-
Click and Type methods.
-
Methods based on a control type's supported patterns. You can use the supportedpatterns description property to check what patterns an object supports.
-
Some test objects have object-specific test object methods available for use.
For full details on these test object methods, see the UIAPro section of the Object Model Reference.
Note: The test objects and methods available are completely dependent on the properties and patterns implemented in your application. We recommend that you familiarize yourself with the properties of your application's objects - specifically the Control Type IDs and supported patterns to understand what test objects and methods you can use.
Leverage the enhanced Beta UIA Pro Add-in
An enhanced version UIA Pro Add-in is available as a Beta offering. To use this version, you must specifically activate it, as described in Activate the enhanced Beta UIA Pro Add-in.
This section describes the advantages provided by this enhanced version.
Note: Changes in the Object Model Reference may require you to adjust your tests when you switch between the legacy UIA Pro Add-in and the enhanced Beta one.
Area | Enhancement |
---|---|
Performance and stability |
The Beta version of the add-in provides:
|
Object hierarchy: Test object tree navigation |
UI Automation applications often have deep object hierarchies. The enhanced add-in supports full access and interaction with all of the objects in the hierarchy. New methods enable comprehensive and flexible traversal of the test object tree:
For details, see the following methods in the UIAPro section of the Object Model Reference: GetAncestors, GetChildren, GetDescendants, GetParent. Use these methods instead of the ChildObjects method, which is still supported for backward compatibility. |
Object hierarchy: Spying | The Object Identification Center shows the full hierarchy of a spied UIA Pro object. When adding a test object to the Object Repository, only its most significant ancestors are included. |
Object hierarchy: Common methods and properties |
Common methods and properties are supported on objects retrieved during a run session, such as by the GetCell method. The newly supported methods are: Exist, GetROProperty, GetTOProperty, SetTOProperty, Highlight, RefreshObject, ToString, CheckProperty, WaitProperty. This enables robust tests that can interact with objects found during runtime in the application's object hierarchy. For example, the following statement is supported in the enhanced Beta add-in and not in the legacy one:
|
More specialized object descriptions |
Assistive properties are supported, enabling the creation of optimized test object descriptions. In the Legacy UIA Pro Add-in, all object identification properties are included in all UIA Pro test object descriptions. In the Beta Add-in, you can see in the Object Identification dialog box which properties are considered for each type of UIA Pro test object. For details, see Configure object identification for a test object class. Currently, you cannot edit this list of properties, but after a test object is added to the Object Repository, you can edit its description, modifying the list of properties used to identify it, as well as their values. |
Fixed known defects |
The following known issues have been fixed:
|
Object Model Reference changes |
The following changes in the Object Model Reference may require you to adjust your tests when you switch between the legacy UIA Pro Add-in and the enhanced Beta one. In the enhanced Beta add-in:
|
Activate the enhanced Beta UIA Pro Add-in
After you install and enable the UIA Pro Add-in, you can activate or deactivate the enhanced Beta functionality.
Task | Instructions |
---|---|
To activate the enhanced UIA Pro functionality, turn off the default add-in. |
|
To return to the default UIA Pro Add-in functionality, turn on the default add-in. |
|
Known issues when using either UIA Pro Add-in
These known issues are relevant when working with the UIA Pro Add-in, regardless whether it's the legacy or enhanced add-in.
Known issues | Description |
---|---|
Recording | Recording UIA Pro steps is not supported. |
Parameter value enumerations |
When entering a parameter value in a UIA Pro test step, use integer values rather than enumeration strings. Example: In the syntax
|
Unsupported properties | The Object property, used to access the native methods and properties of an object, is not supported in UIA Pro. |
Known issues when using the legacy UIA Pro Add-in
By default, the legacy UIA Pro Add-in is used. There are some known issues when working with this add-in.
Known issues | Description |
---|---|
Object hierarchy: Spying |
UI Automation applications often have deep object hierarchies. This add-in has limited access to contained objects. The Object Identification Center shows only a limited hierarchy of a spied UIA Pro object. To see the full hierarchy, use the Object Spy. |
Object hierarchy: Interacting with objects |
Most common methods and properties are not supported on objects retrieved during a run session. |
Assistive properties | Assistive properties are not supported in UIA Pro, and all properties included in an object's description are considered mandatory. |
Known issues when using the enhanced Beta UIA Pro Add-in
There are some known issues when working with the enhanced Beta UIA Pro add-in.
Area | Known issue |
---|---|
OIC |
In the OIC, you can only spy on objects, highlight them, and add them to the object repository. A test object description is created, based on the properties listed in the Object Identification Dialog Box. However, the OIC does not indicate which properties are included, nor can you modify the selection using the check boxes. |
Object Spy |
The following known issues are relevant when working with the Object Spy:
|
Object synchronization timeout | UIA Pro steps always use the default Object Synchronization Timeout value (20 seconds), ignoring any other value defined in the test settings. |
Ordinal identifiers | The Index ordinal identifier is supported, but the Location and Visual relation identifiers are not supported yet. |
Unsupported methods |
The following methods are not supported on UIA Pro test objects:
|
Run result reports |
The following known issues are relevant for run result reports:
|
See also:
-
For details on Microsoft UI Automation patterns, see the UI Automation overview on MSDN.