This is a simple UI automation framework built with:
- Python: 3.10, pytest 7.2.0, Selenium: 4.11.2 and GitHub Actions CI
- Easy-to-use UI automation framework.
- Based on popular Python libraries: pytest and Selenium.
- Supports Chrome,Firefox and Remote browsers for UI testing.
- Provides utilities for setting up and managing WebDriver instances.
- Supports GitHub Actions CI workflow for Darwin(Mac) and Linux
- Supports different environments: dev, stage
- Supports pytest reports and custom logs
- Python 3.8-3.11
- Note, if you are not using MacOS with arm64 architecture or Selenium version below 4.11.0, upload the appropriate driver corresponding to your OS to the resources directory
- Clone this repository
- Install required dependencies with
pip install -r requirements.txt
- Create .env file and add
DEV_URL = "your-dev-project-url"
STAG_URL = "your-staging-project-url"
- If you don't want to use environment variables, add your references to the properties file
class Properties:
_ENV_VARIABLES = {
"dev": ("DEV_URL", ""),
"stag": ("STAG_URL", ""),
# Add more environments and their default URLs as needed
}
- It is possible to download the latest version of the driver for MacOS arch64 using chromedriver.sh located in the resources folder
- While running CI on your local, git resources must contain proper chrome driver with x86_64 architecture
- (unless you are using selenium version 4.11.0 and higher)
- Go to repository settings -> secrets and variables -> actions -> variables and add DEV_URL, STAG_URL
- Added CI configuration to run tests for ubuntu run_test_ubuntu.yaml