Relevant for: GUI tests and components
Insight enables UFT One to recognize objects in your application based on what they look like, instead of properties that are part of their design. This can be useful if you are working with an application whose technology is not supported by UFT One, or with an application running on a remote computer.
Note: Insight is supported only on the primary monitor.
With Insight, UFT One stores an image of the object with the Insight test object (along with ordinal identifiers, if necessary), and uses this image as the main description property to identify the object in the application.
You can create InsightObject test objects during recording sessions, or when adding test objects to an object repository manually.
When adding objects to an object repository, you can add an object directly from the application, or even from a picture of the object displayed on your screen.
In the object repository, you can edit the object's properties, such as its name and image, and the default location to click in the control when performing test object methods. You can also define visual relation identifiers to improve UFT One's ability to accurately identify the object.
UFT One learns Insight objects using the following elements:
UFT One stores an image of the object, and uses this image as the main description property to identify the object in the application.
UFT One also uses the following additional description properties to ensure unique identification:
If parts of the object do not always look the same, you can instruct UFT One to ignore those areas when it uses the image to identify the object.
UFT One can use an ordinal identifier to create a unique description for the object.
Other aspects of object configuration, such as mandatory and assistive properties, and smart identification, are not relevant for Insight test objects.
|Visual relation identifiers||
After UFT One creates a description for an Insight test object, add visual relation identifiers to improve identification of the object.
The Insight object is always added to the object repository as a child of the test object that represents its containing application, such as a Window or Browser object. (The new object's parent object is also added if it does not already exist in the object repository.)
Note: Insight test objects require more disk space than other test objects, because of the test object images and the snapshots stored with the test objects.
To control the amount of space used, limit the size of the snapshot in the Insight & Text Objects Pane (Options Dialog Box > GUI Testing Tab).
After you add all of the relevant test objects and finish modifying them to your satisfaction in the object repository, you can delete all of the snapshots to reduce the amount of disk space used.
Create steps using Insight test objects in much the same way as you would with other types of test objects.
In the Editor, the test object image is displayed in the step instead of the test object name. When you hold the cursor over the image, an enlarged view of the image is displayed. Double-click the image to open the object repository with the InsightObject selected.
Tip: To show these images, select the relevant option in the Options dialog box (Tools > Options > GUI Testing tab > Insight pane).
For details on the methods and properties supported by Insight test objects, see the Insight section of the UFT One Object Model Reference for GUI Testing.
During a run session, UFT One searches for the Insight test object that matches the image stored with the test object.
UFT One searches for the matching object within the Insight object's parent test object. You can help focus the search on a smaller area by creating smaller parent objects and building a hierarchy of Insight test objects in your object repository.
UFT One's image matching algorithm allows for some variation, enabling UFT One to recognize the object even if it changed slightly. However, the algorithm is not based on object properties, and therefore does not use the smart identification mechanism.
Note: Steps with Insight objects may take longer than usual to run, especially if there are many similar objects with the same parent.