{"id":16535638,"url":"https://github.com/hjsblogger/auto-healing-with-selenium","last_synced_at":"2026-04-21T03:33:28.335Z","repository":{"id":186518380,"uuid":"675299702","full_name":"hjsblogger/auto-healing-with-selenium","owner":"hjsblogger","description":"This repo deep dives into running Auto-Healing tests using Selenium and LambdaTest","archived":false,"fork":false,"pushed_at":"2023-09-18T18:30:14.000Z","size":32,"stargazers_count":2,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-03T15:24:12.283Z","etag":null,"topics":["auto-healing","automation-testing","lambdatest","selenium","selenium-java","selenium-webdriver"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hjsblogger.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-08-06T13:16:09.000Z","updated_at":"2025-01-01T12:52:06.000Z","dependencies_parsed_at":null,"dependency_job_id":"a8676e13-365e-4617-9ca5-fbbfbd352b87","html_url":"https://github.com/hjsblogger/auto-healing-with-selenium","commit_stats":null,"previous_names":["hjsblogger/auto-healing-with-selenium"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hjsblogger/auto-healing-with-selenium","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hjsblogger%2Fauto-healing-with-selenium","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hjsblogger%2Fauto-healing-with-selenium/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hjsblogger%2Fauto-healing-with-selenium/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hjsblogger%2Fauto-healing-with-selenium/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hjsblogger","download_url":"https://codeload.github.com/hjsblogger/auto-healing-with-selenium/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hjsblogger%2Fauto-healing-with-selenium/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32075243,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-21T02:38:07.213Z","status":"ssl_error","status_checked_at":"2026-04-21T02:38:06.559Z","response_time":128,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["auto-healing","automation-testing","lambdatest","selenium","selenium-java","selenium-webdriver"],"created_at":"2024-10-11T18:28:25.333Z","updated_at":"2026-04-21T03:33:28.319Z","avatar_url":"https://github.com/hjsblogger.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Auto Healing in Selenium using LambdaTest \n\nIn this 'Auto Healing in Selenium using LambdaTest' repo, we have covered the following use cases:\n\n* \u003cb\u003eAuto Healing of live document\u003c/b\u003e\n* \u003cb\u003eAuto Healing of document (under development) \u003c/b\u003e\n\nThe following websites are used for the purpose of demoing the use cases:\n\n* [LambdaTest E-commerce Playground Registration Page](https://ecommerce-playground.lambdatest.io/index.php?route=account/register)\n* [LambdaTest E-commerce Playground Product Page](https://ecommerce-playground.lambdatest.io/index.php?route=product/category\u0026path=57)\n* [Demo Login Page created by Florin Pop](https://codepen.io/FlorinPop17/pen/vPKWjd)\n\nThe [Demo Login Page](https://codepen.io/FlorinPop17/pen/vPKWjd) is hosted locally and run on port number 8080 (or any other port) that is currently free on the system.\n\n## Pre-requisites for test execution\n\nFor localhost testing, we need to start the tunnel. To do the same, download [Underpass](https://www.lambdatest.com/support/docs/underpass-tunnel-application/#downloading--installing-the-underpass-tunnel-application) from LambdaTest to establish an SSH tunnel between the OS \u0026 LambdaTest cloud server(s).\n\n\u003cimg width=\"798\" alt=\"UnderPass\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/987a5aa4-ef8d-45dd-a4b0-f8b6bcbf4991\"\u003e\n\nLoad the [demo login page](https://github.com/hjsblogger/auto-healing-with-selenium/tree/main/local-project/dist/index.html) by triggering the ```php -S localhost:8080``` command on the terminal.\n\n\u003cimg width=\"794\" alt=\"TestMethod_3 1\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/541fc76f-8330-4689-b32a-760df04565d8\"\u003e\n\nBefore running the tests on LambdaTest Selenium Grid, you need to set the environment variables - *LT_USERNAME* and *LT_ACCESS_KEY*. Here is how you can do the same:\n\n## Configure Environment Variables\n\nBefore the tests are run, please set the environment variables \u003cb\u003eLT_USERNAME\u003c/b\u003e \u0026 \u003cb\u003eLT_ACCESS_KEY\u003c/b\u003e from the terminal. The account details are available on your [LambdaTest Profile](https://accounts.lambdatest.com/detail/profile) page.\n\n\u003cimg width=\"970\" alt=\"SecurityPage\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/d2d061d7-a320-4b97-9b23-5663bfa4b721\"\u003e\n\nFor macOS:\n\n```bash\nexport LT_USERNAME=LT_USERNAME\nexport LT_ACCESS_KEY=LT_ACCESS_KEY\n```\n\nFor Linux:\n\n```bash\nexport LT_USERNAME=LT_USERNAME\nexport LT_ACCESS_KEY=LT_ACCESS_KEY\n```\n\nFor Windows:\n\n```bash\nset LT_USERNAME=LT_USERNAME\nset LT_ACCESS_KEY=LT_ACCESS_KEY\n```\n\nAlso, add *LT_USERNAME* and *LT_ACCESS_KEY* in the *set-env* section in the [Makefile](https://github.com/hjsblogger/auto-healing-with-selenium/blob/main/Makefile)\n\n![Code1](https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/fe2fec54-9c67-4bd7-a352-81b58bbd50c7)\n\nRun ```make set-env``` to export the desired environment variables (i.e. *LT_USERNAME* and *LT_ACCESS_KEY*).\n\n## Test Execution\n\n### Execution of tests [with unchanged locators]\n\nTo start with, we run the tests (with original locators) by invoking ```make org-test``` to execute tests that have locators that have not been modified during the development process. Hence, we will not observe any auto-healing of locators in this test execution cycle.\n\n![Make3](https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/296771b4-5fe4-416e-9c94-2e3d08f6b34f)\n\nTest execution is triggered with all three tests running in parallel on LambdaTest Selenium Grid.\n\n\u003cimg width=\"1406\" alt=\"Make-Org-Test-New\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/52a83cd0-a469-419a-a6d5-23383f31a825\"\u003e\n\n\u003cimg width=\"1400\" alt=\"make-org-test-completed\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/8d1f5c87-440c-4da4-b654-6cc1303fd417\"\u003e\n\nShown below is the execution snapshot which indicates that the test execution was successful.\n\n\u003cimg width=\"1430\" alt=\"org-test-dashboard-running\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/a2d9d49b-c1a6-458c-bf05-9b8eb4ae1285\"\u003e\n\n\u003cimg width=\"1430\" alt=\"org-test-dashboard-completed\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/b1386c67-3440-4872-bfa4-868c50c2d359\"\u003e\n\n### Execution of tests [with healed locators]\n\nThe test code with modified locators is present in *AutoHealingTest.java* Run the command ```make auto-heal``` to execute the tests that have locators healed by the auto-healing algorithm.\n\n\u003cimg width=\"1407\" alt=\"Make-Auto-Heal-New\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/a80e3854-e6cc-4582-9b2c-c310ce1b45d5\"\u003e\n\n\u003cimg width=\"1429\" alt=\"Test_auto-healing-dashboard-1\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/2720df45-90f3-4034-b753-6a2ad4d19512\"\u003e\n\nAs seen below, the test execution was successful. However, there is a small *bandage* icon (for indicating healed tests) next to the respective tests. This indicates that the tests are healed when potential failures are encountered during the course of test execution.\n\n\u003cimg width=\"1409\" alt=\"Auto-Healing-Terminal\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/f7c19526-9509-4924-956e-c98265151d80\"\u003e\n\n\u003cimg width=\"1427\" alt=\"Auto-Healing-Dashboard-2\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/8905cce9-411a-4a9c-a892-53baf7e8ca66\"\u003e\n\n\u003cbr/\u003e Navigate to the respective test in the [LambdaTest dashboard](https://automation.lambdatest.com/build) and click on the *Bandage* icon to view details of the test.\n\n\u003cimg width=\"1424\" alt=\"Healed-Locator-in-Testing\" src=\"https://github.com/hjsblogger/auto-healing-with-selenium/assets/1688653/c3c531cc-6d33-41a1-b042-27a238484b53\"\u003e\n\n\u003cbr/\u003e For further reference, please visit [Official Documentation of Auto Healing on LambdaTest](https://www.lambdatest.com/support/docs/auto-healing/)\n\n## Have feedback or need assistance?\nFeel free to fork the repo and contribute to make it better! Email to [himanshu[dot]sheth[at]gmail[dot]com](mailto:himanshu.sheth@gmail.com) for any queries or ping me on the following social media sites:\n\n\u003cb\u003eLinkedIn\u003c/b\u003e: [@hjsblogger](https://linkedin.com/in/hjsblogger)\u003cbr/\u003e\n\u003cb\u003eTwitter\u003c/b\u003e: [@hjsblogger](https://www.twitter.com/hjsblogger)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhjsblogger%2Fauto-healing-with-selenium","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhjsblogger%2Fauto-healing-with-selenium","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhjsblogger%2Fauto-healing-with-selenium/lists"}