Skip to content

Tesena-smart-testing/selfhealing-robot-framework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

53 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Self-healing Selenium Tests in Robot Framework using Healenium

Healenium is a tool based on Selenium that provides capability to heal (re-generate) a locator once the element could not be found. Read more about this tool at https://healenium.io

This is solution is based on the Healenium Docker containers for Python provided by the open-source project at https://github.com/healenium/healenium-example-python

Disclaimer

Please note that this is just a proof of concept, testing and debugging is still ongoing.

We would be happy to know your comments or issues on following e-mail: [email protected]

Prerequisities

  1. install Python v3.9 or newer: https://www.python.org/downloads, including pip
  2. using commandline terminal, navigate to the project root and create a new virtual environment and activate it
    • python -m venv venv or for MacOs python3 -m venv venv
    • .\venv\Scripts\activate or for MacOs source venv/bin/activate
  3. install required libraries using pip:
    • pip install -r requirements.txt
  4. install and run Docker Desktop: https://www.docker.com/products/docker-desktop
  5. in the project directory, start commandline terminal and start the Healenium Docker containers using following commands:
    • docker-compose up -d - download Docker images and create containers
    • docker ps - list the created containers

Before running `docker-compose up -d`` on MacOs comment out lines 9 and 10:

volumes:
  - ./db/sql/init.sql:/docker-entrypoint-initdb.d/init.sql

New version of the lines should look like:

# volumes:
#   - ./db/sql/init.sql:/docker-entrypoint-initdb.d/init.sql
  1. verify that following containers are up and running (either in the previous terminal output or directly in Docker Desktop client):
    • healenium/hlm-backend
    • postgres:11-alpine
    • healenium/hlm-proxy
    • healenium/hlm-selenium-4-standalone-xpra
    • healenium/hlm-selector-imitator

How to execute tests

Using commandline from project root:

  • robot -d results tests/healenium_test.robot

To see the test execution, you can open http://localhost:8086 in your browser (replace localhost by the name of your server if running remotely)

About

Self-healing Selenium Tests in Robot Framework using Healenium

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •