Skip to content

ralucaoanapopa/learn-py-playwright-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Setup

  1. Download and install Python 3.x
  • If it is already installed, check in terminal:
python --version
  1. Make sure to have the latest pip version installed
python.exe -m pip install --upgrade pip
  1. Install the pytest playwright plugin
pip install pytest-playwright
  1. Install the required browsers (chromium, firefox, webkit)
playwright install

Pre-requisites

Credentials used in tests need to be set as environment variables.

In order to see the list of tests:

pytest --collect-only

By default tests will be run on chromium, in headless mode:

pytest

Using pytest CLI options can choose another browser and headed mode:

pytest --browser webkit --headed

Run only one test suite

pytest <test_file>.py --headed

Run all tests from root

python -m pytest

Results

All tests

All tests

Resources

Tools & frameworks

Free websites for UI testing