Learn Object Spy in UFT – User friendly Tech help

Hello Friends!! My name is object spy. You can find me in my new avatar of hat and goggles in UFT. Today I am going to tell you about myself.
n

n

n

n

n

n

n

n

n

My new look 

n

Introduction to Object Spy?

n

I am an inbuilt tool which comes bundled with UFT, I help automation testers with following capabilities:-

n

You can find my brothers in Selenium.

n

1. Highlight the object. (How to do highlight in Selenium)

n

2. Adding objects to Object repository.

n

3. Check the properties of object (also you copy that to clipboard).

n

4. Check what all the operations that can be performed on the object.

n

n

n

n

n

n

n

n

Object Spy UFT

n

How to launch me?

n

1.       From menu bar icon

n

n

n

n

n

n

n

n

Launch from Menu Bar

n

2.       Tools -> Object Spy

n

n

n

n

n

n

n

n

Object Spy launch from Tools

n

3.       Resources -> Object  Repository Manager

n

n

n

n

n

n

n

n

Launch from object repository manager

n

4.       Resources -> Object Repository

n

n

n

n

n

n

n

n

Launch from local OR

n

Understand my UI?

n

Hand: – This is the point where you can start my interaction with the objects, just click it and move my hand over the required object and ill provide you the properties which is consumed by UFT in object identification. Moreover you can press CTRL key to hide my hand to perform normal operations of mouse.

n

n

n

n

n

n

n

n

Working with hand icon in object spy

n

Highlight:–

n

This feature of mine will be disabled until and unless no object is added to my UI.

n

n

n

n

n

n

n

n

Highlight is disabled 

n

n

n

n

n

n

n

n

Highlight/add to OR/ Copy to clipboard are enabled one’s object is added

n

One’s the object is added ill help you highlight that particular object in the application (with a blink around that object.)

n

Note: – 

n

Incase I am not able to find the object due to nonexistent of object or properties are not unique, I’ll generate an error message like below.

n

n

n

n

n

n

n

n

Error message for non exiting object in application 

n

Add object to object repository (OR):–

n

Using this feature you can add the selected object to object repository.

n

n

n

n

n

n

n

n

Add objects to OR

n

Note:

n

    n

  • Only the selected object from the hierarchy will be added to OR
  • n

  • One’s that object is added to OR, this button will become disabled and small bucket like symbol will appear next to the object.
  • n

  • Object will be added to local Object repository incase i am launched from Local object repository or from menu bar icon or from tools options. I will add object to shared OR only incase i am launched from object repository manager.
  • n

n

n

n

n

n

n

n

n

Object added to OR 

n

Copy to clipboard:-

n

Click on this button to copy all the object properties in ,name:=value pair combination. 

n

n

n

n

n

n

n

n

Copy to clipboard in Object Spy

n

Paste them in any of the editor say notepad, to employ in automation.

n

n

n

n

n

n

n

n

Copied object properties from object spy

n

Note:– 

n

This feature is important while working with descriptive programming(DP) in UFT, as you can utilize this properties in DP.

n

Keep me on Top while spying:-

n

You can keep me on the top of the application while hand button is active or make me invisible while object spy is active.

n

n

n

n

n

n

n

n

Keep object Spy in top of Application while spying 

n

Tips:

n

I am really powerful, as when I am active, you can’t perform any operation in UFT, so you need to close me before you can work on UFT or Object repository manager.

n

How to work with me:–

n

Launch me -> click on hand -> hover over the object with which you want to work -> select it -> Try to highlight (to cross check that we have captured the correct object) -> add to OR / copy to clipboard/ check properties or operations that can be performed on object

n

Note:

n

    n

  • Under properties: – we can select identification and native properties/operations.
  • n

  • Identification Properties are properties that UFT uses to identify objects in application, these come as name value pairs like “title: =HOME”.
  • n

n

n

n

n

n

n

n

n

Object spy Identification Properties

n

When to use Native properties/operations?

n

Sometimes my identification properties are not enough to fulfil many automation requirements. To deal with these problems you can leverage ‘Native Properties’ of the application under test.

n

Note:-

n

You can retrieve native properties value for an object using .object

n

Below example shows the native properties/methods of link object.

n

n

n

n

n

n

n

n

Working with Native properties and Methods

n

You can find the same native methods/properties for link in my UI.

n
n

n

n

n

n

n

n

n

Link Native methods

n

    n

  • Native properties are properties as created by the creator of object, e.g. Microsoft is creator for IE explorer objects.
  • n

  • Identification properties are subset of native properties.
  • n

  • We can use .object to retrieve Native Properties, utilize native operations, and manipulate native properties.
  • n

n

Hope this crisp introduction about myself, help You know and understand my usage in UFT. Do share your comments or feedback below . Will be happy to hear from You. Bye bye J

Was this article helpful?
YesNo

Similar Posts