Auto Healing

Modified on Mon, 20 May 2024 at 12:16 PM

Auto Healing Overview

The auto healing feature is a solution designed to address test issues caused by changes in the application being tested.  Auto healing feature is applicable to Web Automation for Java Selenium, C # Selenium, Python Selenium and Typescript Playwright frameworks; Desktop Automation for  TestComplete and C# WinaAppDriver frameworks; and  Mobile Automation for Java Appium framework.


algoQA generates scripts with the aim of being easily comprehensible and maintainable. These scripts can be executed in the programming language of your choice. They are organized in a structured folder system to make them easier to manage.

When the application being tested changes, the scripts may face issues locating specific elements. If this happens, the script might fail to execute. However, with algoQA's auto-healing feature enabled, it automatically identifies and fixes these issues with broken elements. This allows the scripts to run successfully in the subsequent test runs.



Note: Auto healing feature doesn't apply to changes in the workflow of the application.


For example, consider a scenario where a web application updates its login process. Initially, there is a "Login" button labeled with the ID "loginButton"


<button id="loginButton">Login</button>
Later, the button ID is changed to "signInButton":
<button id="signInButton">Sign In</button>

When  auto-healing feature is enabled in a test scenario, the script searches for the element with the ID "loginButton". It fails to find it, the test will result in failure.  Then feature recognizes that despite the change in ID to "signInButton", the button's functionality remains the same. It adjusts its search criteria to locate the "signInButton", ensuring the test can proceed without any issues.




How to Enable the Auto Healing Feature

Prerequisite

  • To install auto healing feature, you must first download auto healing executable file. Navigate to Downloads link on the algoshack website and download the auto-healing exe file.
    Note that if you have subscribed to the algoQA platform, you will be able to access Downloads link.
  • An executable (exe) file contains a set of instructions that can be executed or run by a computer, commonly used in Windows operating systems to launch applications or perform specific tasks. An auto-healing executable (exe) file helps in setting up and configuring the auto-healing feature in an application.  To configure the executable file, refer to the article Configuring Auto Healing Feature.


Perform the following

  1. After generating the script, download it to your local folder. This folder must contain the script file that you have  generated.

  2. Open the folder where you downloaded the script. For example, if your script is located at AlgoAFScript_202402121131\src\test\java, navigate to this folderApplications.xml file will be available in the Java folder as shown:
  3. Open the application settings file and locate the setting related to the auto-healing feature. Set this setting to True to enable auto-healing feature.
  4. After setting the auto-healing feature to True, save the changes you have made to the application settings file.













Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select atleast one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article