Header

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Next »

Object Spy for Internet Explorer

Object Spy supports CRUD operations to manage objects.

Prerequisites

  • Ensure you have Full control rights to the folder and subfolders where Object Spy is getting installed.
  • Ensure that the Active scripting option is set to Enable under Security Settings section. To do so, under Internet Options > Security > Custom Level.  
    By default, this option is set to Disable in the high security zone.
 View Image

  • Ensure that Enable third-party browser extensions* is enabled from the Advanced section of Internet Options.  
 View Image

Object and their Attributes

Objects

Internet Explorer Object Spy does not support adding objects for a SFDC application.

Object Attributes

  • Name
  • ID
  • Class
  • Name: Sign in
  • Color: Blue

Selection of Attributes

Static and Dynamic Objects

Static Objects

Dynamic Objects

Locator Priority Settings

Locator Types

  • Link
  • Name
  • ID
  • XPath
  • CSS
  1. On Object Spy toolbar, click the Settings icon.
    The Locator Priority Settings window appears.
    1. Click Up/Down buttons to changes the priorities of the locator type.
    2. Click Restore Default to restore the default priorities.
    3. Click Cancel to discard changes.
    4. Click Ok to apply the changes.

Object Learning Algorithm

When Object Spy overrides the preferred locator type even if the object has Name or ID Attributes

Objects under Frame

Object Identification Failure

  • Object does not exist
  • Object exists but tool failed to identify

Selecting Capture Mode and API

Capture Mode

  • Left Click: In this mode, you can add objects to the repository using the left click of the mouse.
  • Mouse Hover: Using this mode, you can add objects in the repository just by hovering mouse pointers over objects.
  1. Launch Object Spy.
  2. Go to Settings > Inspection.
  3. In Capture mode, select the required option.
  4. Click OK

Capture APIs

  • Browser Mode: In this mode, Qualitia identifies objects using JavaScript events or native events.
  • Accessibility: Selecting this mode, you can utilize Microsoft Active Accessibility API to identify objects from application under test more reliably.
  1. Launch Object Spy.
  2. Go to Settings > Inspection.
  3. In Capture API, select the required option.
  4. Click OK.

Launching Object Spy

If Anti-virus of your computer stops launching Object Spy, you need to whitelist the object spy's extension in the Anti-virus. 

  1. Open the Qualitia Automation Studio client.

  2. From the Expand Menu, click Develop.

  3. Click the Objects tab.
  4. Click the Spy button. as shown in the following figure:

  1. You are prompted with the following confirmation message:
  1. Click Yes if you have administrative privileges. You will not be able to continue with the installation if you do not have administrative privileges.
    The following Windows confirmation message appears:
  1. Click Yes.
  2. Internet Explorer opens, and you will see Object Spy at the bottom as shown in the following figure:
  • Right-click the Test case or Task screen, and select from the context-menu Object Spy.

Object Spy User Interface

  1. Object Spy tab
  2. Tree view
  3. Grid view
  4. HTML tab
  5. Button to change Object Inspection Mode
  1. Object Name
  2. Object Description
  3. Object Class
  4. Locator Type
  5. Locator Value
  6. SmartLocator
  1. Highlight
  2. Clear Highlight
  3. Save
  4. Delete
  5. Reset
  6. Search
  7. Settings

Adding Objects Using Different Modes

  1. From the Objects screen, click Spy.
    The Object Spy window appears.
  2. Navigate to the page from where you want to add objects.
  3. Ensure that Select Object option is disabled. 
  4. Point to an object that needs to be added.
    The object is highlighted with a blue border.
  5. Right-click the object and select Add Object from the context-menu.
    A confirmation message appears after the object is added.
    An object is added to the repository using the precedence set in Locator Priority Settings.
  • While pointing to an object ensure you have pointed to an object with its appropriate Object Class.
  • Objects that are added manually with CSS/DOM Locator Type values cannot be highlighted.
  • When adding new object in the repository, if object already exists, Qualitia notifies displaying the object name that is used while adding this object into the repository.

Left-Click Mode

  1. From the Objects screen, click Spy.
    The Object Spy window appears.
  2. From the Settings > Inspection. 
  3. Select Capture Mode as Left-Click and click OK.

  4. Navigate to the page from where you want to add objects.
  5. Ensure that Select Object option is enabled.
  6. Left-click the object which you want to add into the repository.
    A confirmation message appears after the object is added.

When adding new object in the repository, if object already exists, Qualitia notifies displaying the object name that is used while adding this object into the repository.

Mouse Hover

  1. From the Objects screen, click Spy.
    The Object Spy window appears.
  2. From the Settings > Inspection. 
  3. Select Capture Mode as Mouse Hover and click OK.

  4. Navigate to the page from where you want to add objects.
  5. Ensure that the Select Object option is enabled.
  6. Hover the mouse pointer over the object which you want to add into the repository.
    A confirmation message appears after the object is added.

When adding new object in the repository, if object already exists, Qualitia notifies displaying the object name that is used while adding this object into the repository.

Selecting Object Attribute On-The-Fly

  1. From the Objects screen, click Spy.
    The Object Spy window appears.
  2. Navigate to the page from where you want to add objects.
  3. Right-click the object and select Add Object By from the context-menu.
  4. Select the object attribute using which you want to add object into the repository.
    A confirmation message appears after the object is added.

    When adding new object in the repository, if object already exists, Qualitia notifies displaying the object name that is used while adding this object into the repository.

Adding Objects from HTML Code View

Adding Objects from Modal Dialogs

  1. Launch Object Spy.
  2. Go to Settings > Inspection.
  3. Select the Allow Modal Inspection option.
  4. Click OK.
    Now you can add objects from modal dialogs and use them while creating new tasks and test cases.

Searching Object

  • Search by Object Name
  • Advanced Search

Search by Object Name

  1. On the Object Spy window, enter the object name you want to search.
  2. Click Search.
    When you select objects from the search results, immediate parent will be highlighted for easy identification.

Advanced Search

  1. On the Object Spy toolbar, click the Search icon.
    The Object Search window appears.
  2. Select the appropriate filter (Name, Object Class, Locator Type, or Locator Value) to search an object.
  3. Click Search.

Editing Object Details

  • Press F2 key or double-click the cell.
  • Use arrow keys to traverse from one field to another.
  • Use the Enter key to save the data.

Objects not used in Test cases or Tasks can be edited. If objects that are used in Test cases or Tasks are edited, then Qualitia notifies for confirmation before allowing any edits.

Resetting Objects

  • On the Object Spy toolbar, click Reset.
    This will discard any unsaved changes.

Deleting Objects

  1. On the Object Spy grid-view, select the check box(s) corresponding to the objects that you want to remove.
    Select the check box at the top of the column to select all the objects.
  2. On the Object Spy toolbar, click Delete.
  • An object can only be deleted from the Object Spy, if it is not in use in the test case development.
  • Delete operation is permanent and cannot be reverted.
  • If you try to delete a page or frame object, you will be prompted to delete all child objects first and then delete the page object.

Highlighting Objects

Highlight

  1. Navigate to a page from which objects are added earlier.
  2. Select an object from the Object Spy toolbar.
  3. To select all objects, select the check box at the top of the column.
  4. Click Highlight.
    The selected objects get highlighted on the current page with the object name that is used to store in Qualitia.
  5. On the Object Spy toolbar, click Clear Highlight to clear the highlighted object from the current page.

Challenges in Object Identification and Remedies

Duplicate Object Properties

There are situations where you may encounter two objects that are identical to each other with respect to their attributes and values. If you have to deal with one of them as part of your workflow, you need to find some mechanism to differentiate them from each other. This can be achieved by using the following techniques:

  • Find out something unique within the hierarchy (either parent or child or sibling)
  • Use numbering/index or location. Location may fail if resolution is changed and Index may fail if there is an additional, similar object that comes in the next version. The entire indexing may require resetting.

Dynamic Object Properties

Please refer to the Object Identification Failure section.

Container Objects

Please refer to the Object Spy for Internet Explorer section.

FAQs

 How to verify if an Object is already learned?
  • If you try to inspect/add any object and if it is already inspected, an appropriate message appears on the tab bar.
  • Click Highlight All to check if the object is already learned.
 How to know if the Object is used in Test case or Task before deletion or edition?
  • Click Delete checkbox for deleting that object, if it is used in Test case or Task, an appropriate message appears on the tab bar.
  • Select object for deletion and click Save.
  • Double-click on Object Spy grid cell.
 How to edit the XPath or Class of the already Learnt Object?
  • Press F2 key to edit the XPath or Class of the already Learnt Object.
 How to Learn Object by CSS or DOM?
  • Right-click on a page and select Add Object.
  • Change the Locator Type to CSS/DOM
  • Enter the Locator Value and click Save.

(warning) Objects with CSS or DOM Locator Types cannot be highlighted.

 Why Identified Object fail during Test Execution?

Object identification failure can be categorized in following cases:

  • Object does not exist

Object identification failure may be due to network latency, page is heavy to load in the expected time or connectivity failure. This can be handled by synchronization time.

  • Object exists but tool failed to identify

A tool may fail to identify an object when object identification is based on incorrect attributes. Selected attributes might not have a static value. At times, there are properties, which are supposed to be static but contain dynamic values. For example, id attribute is supposed to be static but there are frameworks that generate values of id attribute dynamically. In such cases, your id values are supposed to change every time you refresh a page. On the other hand, there can be situation where a window is identified by title. If title contains timestamp as part of the title, it is prone to change repeatedly after each login. In all such cases, it is advisable to look for other property that is static and uniquely points to the desired object. If there is none and you have to deal with dynamism of the attribute value, check whether the dynamic portion of attribute value is predictable or not.
For example, when user1 logs in, the login window has a title 'welcome user1'. If you change the login credential to user2, welcome will remain the same and the dynamic portion 'user2' is predictable that is 'welcome user2'. Dynamic portion in this case is the same as the user credential used. Same user credential can be passed as part of attribute value.
If dynamic portion is not predictable, then common practice is using regular expression to get rid of the dynamic portion. In the same example of login title, title property can hold a regular expression as 'welcome.*'. You can ignore the dynamic portion and rely on static portion if it uniquely points to the desired object.

Add Object Spy as a Browser Extension

Download the Qualitia Object Spy extension into your Chrome or Edge browser to then launch  it in the browser.

To add Qualitia Object Spy as an extension to a browser:

  1. You can add Qualitia Object spy as an extension to Chrome or Edge browser:
    • To add the Chrome Object Spy:
      1. Download the ChromeExtension folder from the S3 location to your computer.
      2. Extract the QualitiaChromeExtension-8.3.x zip file in a local folder on your computer.
      3. Launch Google Chrome browser and navigate to chrome://extensions/.
    • To add the Edge Object Spy:
      1. Download the EdgeExtension folder from the S3 location to your computer.
      2. Extract the QualitiaEdgeExtension-8.3.x zip file in a local folder on your computer.
      3. Launch Microsoft Edge browser and navigate to edge://extensions/.
  2. Enable Developer Mode.
  3. Click Load Unpacked.
  4. Select the location of the extracted zip file (QualitiaChromeExtension-8.3.x  or QualitiaEdgeExtension-8.3.x), and click OK.

    You can now launch Qualitia Object Spy on the selected browser. For more detailed instructions, Launching Object Spy from the Browser.


Launch Object Spy from Browser

You can launch the object spy from the browser type on which you have added the object spy as an extension.

To launch the Object Spy from the Browser:

  1. Do one of the following:

    1. To launch the Chrome Object Spy, open the Chrome browser.

    2. To launch the Edge object spy, open the Edge browser.

  2. Press F12 to open Developer options and select Qualitia Object Spy.The Qualitia Object Spy login page opens.

  3. Enter the Qualitia Server URL.

  4. Enter the same user id that you use to login to Qualitia Automation Studio (QAS) client ,in User Id.

  5. Click Continue.

  6. Select the associated project on which you want to add and manage objects.

Add Web Application Objects

You can add an object of a web application under test with a single-click and select the locator type of your preference. 

The following is the default sequence to add objects for a web application:

  • Link

  • Name

  • ID

  • XPath

  • CSS

The following is the default sequence to add objects for an SFDC application:

  • SFDC:Label

  • Link

  • Name

  • ID

  • XPath

  • CSS

You can change the locator type sequence as per your requirements. 

Ensure that you have installed Object Spy on the browser of your choice and your computer is connected to Qualitia Server.

Ensure that you have selected a Salesforce project when adding objects of a Salesforce application. 

For adding objects of a Salesforce application, Qualitia recommends using Chrome Object Spy only as Salesforce does not support viewing their applications on Edge.    

To add Web Application Objects:

  1. Launch either Edge or Chrome Object Spy.
    For detailed instructions on how to launch a web object spy, refer to Launching Object Spy from the Browser.
  2. Enter the application under test URL in the address bar.
  3. Enable the Select Mode on.

  4. Hover the mouse pointer over the object and click it once the object details are highlighted.
    The object is added into the list in the Object Spy window.
  5. After adding all the required objects, click Save to Repository.




  6. To add the objects for a child window, do one of the following:
    1. Open the child window, and open its associated Object Spy to add the child window objects to a new child window object repository.
    2. Open the child window. Click the Select Mode button of the Object Spy associated with the parent window to add the child window objects to the parent window object repository. You can switch between parent and child windows to add their objects using the Select Mode button.  

      It is recommended to use Web Object Spy in left dock mode or right dock mode. If you want to use it in any other dock mode, re-enable the Select Mode button to start using it.

      You can also detach Object Spy UI with the application under the test page and also add the child window objects as shown in the above-mentioned step. However, if you are adding objects for multiple application pages in the detach mode, the Web Object Spy adds the objects of all the pages in the same object repository.

Edit an Object using Object Spy

You can update the object details and also change their locator type and associated locator value

To edit an object:

  1. Launch the browser (Edge or Chrome) that is enabled with Web Object Spy.
    For detailed instructions on how to launch a web object spy, refer to Launching Object Spy from the Browser.
  2. In the Repository section, select the page under which the object exists which needs to be updated.
  3. Click the edit () icon next to the object that you want to edit.

    SmartLocator mode does not support HTML tag/structure change.




  4. Modify the object details and then click Save.

Important Notice:

Qualitia SmartLocator automatically identifies dynamic objects during the test case execution. Enabling this option, you cannot edit object details like locator value and locator type.

If you disable this option, this object will no longer be eligible for SmartLocator identification. Please note that if you wish to enable this option for this object later, you will have to perform either of the following steps for SmartLocator to work for this object:

  1. Learn this object afresh using Qualitia Object Spy.
  2. Specify a valid XPath for the object. The object will be SmartLocator enabled only after the first execution.

Highlight the Objects

Qualitia Web Object Spy lets you highlight the added objects when you navigate to the associated application under test page. This helps you to understand which objects are added into the repository and which objects are not added yet.

To highlight the objects:

  1. Launch the browser (Edge or Chrome) that is enabled with Web Object Spy.
    For detailed instructions on how to launch a web object spy, refer to Adding Web Application Objects.
  2. In the Repository section, select the page from which you want to highlight the object.
  3. Do one of the following:
    1. To highlight all objects on the page, click the highlight () icon at the page level.

    2. To highlight a specific object, click the object name you want.
      The application page highlights the objects.

      Objects existing in the repository are highlighted with the green border (as shown in the screenshot above). Objects that do not exist in the repository yet are highlighted with the red border. 

Remove Objects from Object Repository

You can remove the objects that are no longer required. 
To remove an object from the Object Repository:

  1. Launch either Chrome Object Spy or Edge Object Spy.
    For detailed instructions on how to launch a web object spy, refer to Adding Web Application Objects.
  2. In the Repository section, select the page from which you want to remove the object.
  3. Click the Remove icon () next to the object that you want to remove.

You can delete a parent page only when all of its child objects are removed.

Filter Objects List

You can filter objects by page or object type, or both. 

To filter the objects list:

  1. Launch the browser (Edge or Chrome) that is enabled with Web Object Spy.
    For detailed instructions on how to launch a web object spy, refer to Adding Web Application Objects.
  2. In the Repository section, use the filter () option to filter objects.
    1. To filter objects by Web Page, select the desired page from the drop-down list.
    2. To filter objects by Object Class, select the desired object class from the drop-down list.


Limitations/Known Issues

Limitations of Qualitia Object Spy 

  • Does not identify SVG elements.
  • Does not highlight the objects present inside the frames.

Limitations of SmartLocator Feature

  • Does not update the new locator value of the object in the object repository when executing through offline package.
  • Does not support the Wait actions, such as WaitForExistence, WaitForVisibility, and WaitForClickability.

  • No labels