Skip to main content

One of the fundamental steps in automating a UI interaction as part of testing is to set up an identification criterion for various elements that the test needs to interact with. It is one of the critical components that define how stable and hassle-free your automation test will perform.

For example, given a Login test scenario with the following steps

  • Enter username in Username field (an HTML input element of type INPUT)
  • Enter password in Password field (an HTML Password element)
  • Click Login button (an HTML Button element)

Username, Password, and Login fields in the above scenario need to be properly recognized using HTML attributes before performing any action on these (such as entering text or clicking on a button).

Traditional approach

A general approach supported and heavily practiced today is using a standard set of static properties for each element depending on its HTML type. For example, elements of type INPUT will be recognized by their ID, name, class or value properties, etc. based on applicability. This approach has been in use since the inception of test automation and has decently served use cases until a few years back.

Current UI technology landscape

With the proliferation of new-age UI frameworks such as Bootstrap, Angular, JQuery, React, etc. and advanced data-binding models, this approach of element identification has started to prove inadequate. User Experience centric applications with subtle interactions and dynamic data has made this process even more complicated. It also tends to be fragile and sensitive to trivial changes in the application UI.

Identifying an element in the web applications today requires a broader context of the element and understanding of spatial relations with other elements on the page. Element in itself may not offer any of its own attributes to uniquely identify. Automation test API frameworks such as Selenium, offer programming approach to building this comprehensiveness into element ID. But it requires a good understanding of the DOM hierarchy at a technical level and custom programming effort. You usually end up going with straight XPath or CSS based approaches, which could prove to be brittle.

A fresh perspective

accelQ brings unique innovation in this complex and important aspect of a test automation cycle with the following benefits:

  • Automatically construct unique identification with a combination of neighborhood attributes
  • Enable testers to visually analyze element structure
  • Provide real-time feedback with match-count during the analysis process
  • Ability to incorporate regex or pattern at any attribute level
  • Ability to deal with a set of related elements (family of elements) with “anchoring” concept
  • Ability to deal with repeat elements and dynamic content

To identify an element, accelQ analyzes the entire neighborhood and finds a combination of attributes required to bring a stable uniqueness. This could include a combination of ancestor or descendant hierarchy, properties of siblings or linked elements etc. as part of the overall neighborhood. The entire analysis process is visualized so that it is accessible for non-technical audience.

Just one more example of how accelQ is driving fresh innovation in Quality Lifecycle Automation!

MAHENDRA ALLADI

Founder & CEO ACCELQ Inc.

 

This Might Also Interest You...

ACCELQ answers to salesforce test automation challengesBlogSalesforce Test AutomationTest Automation
10 September 2021

How ACCELQ had answers to my Salesforce Test Automation challenges

The software Testing process is a crucial phase in the Software Development Life cycle which used to have a specific timeline during the traditional way of working on projects. However,…
How to choose the right test automation toolBlogCodeless Test AutomationTest Automation
16 August 2021

How to Choose The Right Test Automation Tool

Too many options Yes, this space is more crowded than ever before. It’s easy to get lost with most tools talking about “fancy” capabilities but failing to get the basics…
BlogSalesforce Test AutomationTest Automation
28 October 2021

Key Benefits of Test Automation in Salesforce

Salesforce is considered one of the most preferred CRMs by companies across various industries, thanks to its wide range of cloud-based SaaS offerings, seamless integrations, and continuous innovation. According to…
Close Menu