Playwright with Python
Write browser tests in Python for a synthetic late-fee page: pytest fixtures, role and label locators, retrying assertions, parametrized boundaries, page objects, markers, traces and a deliberate fee-cap defect. Complete source; website checkpoints check notes, not browser runs. A practical path from a user rule to Python browser tests that fail clearly when the page gets it wrong.
- 24
- Lessons
- 8
- Sections
- 8
- Practice labs
- ~12h
- Of content
Sign in to save progress and earn a verified achievement.
1def test_fee_is_capped_at_200(page, days, shown):2 fees = FeePage(page).open()3 fees.calculate(days)4 expect(fees.result).to_have_text(shown)5# pytest6# 6 passed
The method
Built like real QA work, not a video playlist.
Learn
24 focused lessons, each a few minutes long.
Practice
8 hands-on labs in a browser workspace.
Test yourself
8 section assessments plus a final exam.
Prove it
A public, verifiable achievement for recruiters.
What you will learn
- Playwright with Python foundations: Decide what Playwright with Python should prove, Reconstruct the local reference, Use pytest fixtures for the page and base URL
- Locators and actions: Find elements the way users do, Fill, check and click with auto-waiting, Assert with retrying expect
- Designing browser tests: Pick cases from the rules, Parametrize repeated checks, Keep selectors in a page object
- Running and organising suites: Tag tests with markers, Run across browsers and headed mode, Run the suite in CI
- Debugging failures: Record traces for failed tests, Capture screenshots and video, Fix flaky tests at the cause
- Beyond the page: Mock and observe network calls, Reuse sign-in with storage state, Use the API request context
Where you will be at the end
- Complete 8 hands-on practice challenges, one per section (from Playwright with Python foundations to Mutation, retest and portfolio)
- Pass 8 section assessments
- Pass the Playwright with Python final assessment and add the result to your Skill Passport
Who this course is for
- Beginners and manual testers starting this skill from scratch
- Working testers who want to apply it on real projects
- Anyone preparing for QA interviews that ask about this skill
- Best if you already have: Basic Python (functions, imports); Python 3.10+ installed; terminal familiarity
Curriculum
9 sections, one clear path.
- Decide what Playwright with Python should prove
- Knowledge check
- Reconstruct the local reference
- Knowledge check
- Use pytest fixtures for the page and base URL
- Knowledge check
- Browser test evidence: Playwright with Python foundations
- Section assessment
Members-only toolkit
Take the course with you
Made from this course's own lessons, quizzes and labs — ready to revise before interviews or use at work.
Course cheat sheet
Loading…
Interview Q&A pack
Loading…
Lab solutions & hints
Loading…
- Auto-checked labs
- Capstone portfolio project
- Timed final exam
Why paid courses
More than a free course: practice, proof and a portfolio
| What you get | Free | Academy |
|---|---|---|
| Short lessons with examples | ||
| Quick checks and certificate | ||
| Hands-on labs checked automatically | ||
| Section tests and a timed final exam | ||
| Portfolio capstone project with milestones | ||
| Cheat sheet, interview pack and lab answers to download | ||
| Verified skills on your profile and Skill Passport |
What Students Are Saying
Sign in and complete 20% of the course to leave a review.
Share your experience on Trustpilot (optional)
Honest feedback is welcome, whatever your experience. A Trustpilot review is not required for your certificate.
Playwright with Python: common questions
1.Do I need experience before starting Playwright with Python?
2.What can I try for free, and what needs payment?
3.How long does the course take?
4.What do I get when I finish?
Finish with proof, not just a certificate PDF.
Pass the final assessment and get a public verification page showing your score, completion date and the skills you demonstrated — ready to share on LinkedIn.
About this Playwright with Python course
Playwright drives real browsers from Python, and the pytest-playwright plugin gives every test a fresh page. This course teaches it through one small, fully runnable project: a synthetic library late-fee page that charges 10.00 per day, gives members the first two days free and caps the fee at 200.00. Twenty-four lessons in eight sections cover fixtures, locators, assertions, test design, running suites, debugging, network and sign-in techniques, defects and interviews.
Early sections set up pytest fixtures, including a session fixture that starts a loopback server, then find elements by role and label, act with auto-waiting and assert with retrying expect instead of sleeps.
Design lessons pick six cases from the rules, parametrize the cap check with 20 and 45 days and keep selectors in a page object. Suite lessons register a smoke marker, run other browsers in headed mode and describe a CI job. Debugging lessons cover traces, screenshots, video and fixing flaky tests at the cause.
The complete source-map lesson contains requirements.txt, pytest.ini, the page, its loopback server, the fixtures, the page object, the tests and a README. We ran this exact project on Python 3.13 with pytest 8.3.4, pytest-playwright 0.6.2 and Playwright 1.59.0 in Chromium before publishing: 6 passed, and pytest -m smoke ran 1 passed, 5 deselected. Setting BREAK_PW=1 raised the cap to 300.00; 1 test failed with Actual value: Fee: 300.00, and unsetting it restored 6 passed.
Later sections cover writing defects from test evidence, explaining Playwright with Python in interviews, keeping versions healthy and building an honest portfolio with a passing run, a failing mutation run and a restored retest. Network mocking, storage state, API requests and CI are described, not executed. Website checkpoints validate a completed written note and do not run browsers. The certificate records Academy completion, not an official certification.
Who this course is for
- Python testers moving to browser automation
- Selenium with Python users trying Playwright
- SDET interview candidates
What you need
- Basic Python (functions, imports)
- Python 3.10+ installed
- Terminal familiarity
What you will be able to do
- Write Playwright tests with pytest fixtures and user-facing locators
- Design boundary and parametrized browser tests
- Debug failures with traces, screenshots and video
- Prove tests fail on a deliberate defect and report the result
