Manage Repositories

Users can add, edit, and delete the locator repository for all platforms.

QAS has an entity known as the “Locator Repository”, which can be used to abstract element locators outside of the automation code. Moreover, you can have separate locator repositories per environment/platform and configure at run-time to load environment-specific locator repositories.

A Locator Repository is a location where all data(locators) of web element(s) of a web page are stored. Locators are used to find and match the elements of web page. A Locator file contains locator(s), locator description(s), and key(s). Hence, a developer should use the key of a certain locator in order to use the respective locator during execution. Locator strategy can be in the form of name, css, xpath, or id. 

Advantages of Locator Repository

  • Locator repository is a centralized location of the objects and their properties so that if any object information is changed in AUT, you do not need to change the object in all the scripts. It's enough to change in the Locator repository
  • Easily maintain your tests or components when an object in your application changes

Steps to add elements to locator repository

Once you complete your test recording, the actions are displayed on the grid as test steps.

Click on the Repository tab.

A pop-up opens with Elements list at left and locator resources tree at right.

The Key column on the table is editable.

To add elements to the locator repository -

  1. Select the elements you want to add to the locator repository.
  2. Select the folder in which you want to add the elements and click Move & Replace.

You can also add a new repository folder on the tree by clicking on the Add Folder icon.