This is the example project for the Selenium Python pytest tutorial. It shows how to start automating visual tests with Applitools Eyes and Selenium WebDriver in Python.
It uses:
- Python as the programming language
- Selenium WebDriver for browser automation
- pytest as the core test framework
- Google Chrome as the local browser for testing
- pip for dependency management
- Applitools Eyes for visual testing
It can also run tests with:
- Applitools Ultrafast Grid for cross-browser execution
- Applitools Execution Cloud for self-healing remote WebDriver sessions
To run this example project, you'll need:
- An Applitools account, which you can register for free
- A recent version of Python 3
- A good Python editor like Visual Studio Code or PyCharm.
- An up-to-date version of Google Chrome.
- A corresponding version of ChromeDriver.
To install dependencies, run:
pip install -r requirements.txt
The main test case spec is test_acme_bank.py
.
By default, the project will run tests with Ultrafast Grid but not Execution Cloud.
You can change these settings in conftest.py
.
To execute tests, set the APPLITOOLS_API_KEY
environment variable
to your account's API key,
and then run:
python3 -m pytest -s -v tests
For full instructions on running this project, take our Selenium Python pytest tutorial!