Playwright + Python · Lesson 14 of 37
Module 14: Installation & Setup
Your task
Implement make_launch_kwargs(headless=True, slow_mo=0):
Write it in the editor, then press Check answer (Ctrl + Enter).
# Install Python package:
pip install playwright pytest-playwright
# Install browser binaries:
playwright installfrom playwright.sync_api import sync_playwright
with sync_playwright() as p:
browser = p.chromium.launch(headless=False, slow_mo=100)
page = browser.new_page()
page.goto("https://targetqa.com")
browser.close()Installing Playwright for Python takes only two commands. In this lesson, you will install the Python package, download browser binaries with the CLI, configure headed vs headless execution, and run your first test. Let's install Playwright!
Part of the Playwright + Python course (Playwright with Python). Practice this concept live in the Playwright Online Compiler or explore our free automation practice form.
No! 'playwright install' downloads hermetic, dedicated builds of Chromium, Firefox, and WebKit guaranteed to be compatible.
Ready? Solve the task in the editor
Use Check answer to mark it complete. Hints are there if you need them.
___