Most Playwright courses end when the test passes on your laptop. Real teams need more.
They need a framework the whole team can extend without breaking it. They need tests that don't go flaky after a few weeks. And they need a pipeline that runs every test on every merge request and blocks the merge when something is red. That's the gap this course closes.
You'll build a production-grade Playwright framework in TypeScript, step by step, against a practice store made for this course. Then you'll ship it on GitLab CI/CD with Docker, parallel shards, a merged HTML report on GitLab Pages, and a quality gate that blocks merges on failure. By the end you'll have a real, working project you can show in interviews, and you'll know why every part of it is there.
How every lecture works
Every topic follows the same three steps:
- The board. The idea is explained on a blackboard first: what problem it solves and when you'd use it.
- The code. Then it's written in VS Code, line by line, inside the same framework you're building.
- The real run. Then it's proven with a real run: the terminal, the HTML report, the trace viewer, or the GitLab pipeline page.
Nothing is faked. When a test fails on screen, it really failed, and you'll see how to read the failure and fix it.
The practice store
Public demo sites change and go down. This course uses its own practice store instead, a small online shop that runs in Docker on your machine and as a service in GitLab CI. It has:
- logins for different roles, a catalogue, a cart and a checkout;
- an API for seeding data;
- a reset endpoint;
- features that were added because a lecture needed them.
The store will look the same in a year as it does today.
What you'll build, section by section
- Section 1 · Welcome and the finished system. You see the framework and pipeline you'll build, set up Node, VS Code, Git and Docker, and run the practice store and the finished suite. Short refreshers on how Playwright works and the Git merge-request flow.
- Section 2 · TypeScript for test engineers. Types, interfaces, unions, generics, Partial/Pick/Omit, async/await, a strict tsconfig, ESLint, Prettier and path aliases. Only the TypeScript you'll actually use in test code.
- Section 3 · Project layout and configuration. A folder structure that scales, playwright.config.ts line by line, typed environments with dotenv, projects for browsers and setup, webServer, and timeouts that make sense.
- Section 4 · Locators that survive UI change. Why tests go flaky. User-facing locators, test IDs and how to agree them with developers, filtering and chaining, lists and tables, frames, shadow DOM, new tabs, web-first assertions, and the anti-patterns to delete.
- Section 5 · Custom fixtures. Why fixtures beat beforeEach, built-in fixtures, your first custom fixture, test vs worker scope, composition, typed fixtures with mergeTests, and automatic fixtures and options.
- Section 6 · Page and component objects done right. The giant page class problem and the fix: page objects with locators as properties, component objects for the header, cart and product card, injection through fixtures, and a clear rule for where expect belongs.
- Section 7 · Authentication. Log in once per role with storageState and a setup project, handle admin, customer and guest roles, log in through the API for speed, and avoid session and token pitfalls.
- Section 8 · Test data. Isolation over shared data, data factories and builders, realistic data with Faker, seeding through the API, cleanup patterns, parallel-safe data, and verifying data with a SQL query.
- Section 9 · Hybrid UI + API tests and network control. Arrange through the API, act and assert through the UI, wait for and assert on network responses, mock responses with page.route, test errors, slow networks and empty states, and record and replay with HAR.
- Section 10 · Visual and accessibility checks. When visual tests pay off, baselines, thresholds and masking, consistent visual runs in Docker, accessibility scans with axe-core, and ARIA snapshots.
- Section 11 · Parallelism and flakiness. Workers and isolation, sharding across machines, retries with trace on first retry, tagging smoke and regression, finding flaky tests with repeat-each, a quarantine policy, and the debugging toolkit: UI mode, trace viewer and the VS Code debugger.
- Section 12 · Reporting. What developers, leads and CI each need from a report, multiple reporters, steps and attachments that make reports readable, a small custom reporter, and merging shard reports.
- Section 13 · Ship it on GitLab CI/CD. The biggest section, with 14 lectures: your first .gitlab-ci.yml from zero; the official Playwright Docker image, pinned; caching; artifacts and JUnit results inside the merge request; parallel shards with a merge-reports job; rules for merge requests, nightly schedules and manual environments; masked and protected secrets; publishing the report to GitLab Pages; a quality gate that blocks merges; reading a failed pipeline like a senior SDET.
- Section 14 · AI in a production framework. Where AI helps test code and where it hurts. Playwright MCP explores the practice store, Playwright Test Agents plan, generate and heal tests, and you refactor the AI drafts into the framework. Plus the review rules for what never gets merged automatically.
- Section 15 · Maintenance and team practice. A code-review checklist for test code, upgrading Playwright safely, measuring and trimming suite time, deciding what to test at the UI, API and unit level, and documenting the framework for your team.
- Section 16 · Capstone and career. Test a new feature end to end on your own, then compare with the reference solution. Then framework-design interview questions, and how to present this project on your CV and in interviews.
What comes with the course
- Code for every section. A downloadable zip of the code at the start and at the end of each section. The same code is in a public GitLab repository with a tag for every section start and end, so you can always catch up or compare.
- Cheat sheets. A one-page PDF for most lectures with the key code, the commands and the interview answer.
- Section quizzes. A quiz closes every section. Each question tells you which lecture and minute to rewatch, and every quiz ends with a real interview question.
- Rewatch maps. Each section ends with a short summary lecture: what you learned, what's next, and where to rewatch if something didn't click.
- Captions. English captions on every lecture.
Tools and versions
Playwright 1.65, TypeScript 6.0, Node.js 24 (26 works too), Docker, VS Code, Git and GitLab CI/CD on hosted GitLab. Section 14 also uses Playwright MCP and Playwright Test Agents. Section 15 shows how to upgrade safely when new versions come out.
Who this course is not for
If you've never written any code, start with a short JavaScript basics course first. This course assumes you can read a function and a loop. If you only want Cypress or Selenium, this isn't the course for you: everything here is Playwright.
About your instructor
I'm Ojasvi Malik, a senior SDET with more than eight years of building test automation and the pipelines that run it for real product teams. This course is the framework and the CI setup I'd build on a new team, taught in the order I'd build it, with the mistakes I've seen teams make along the way.
How this course is made (AI disclosure)
The welcome video and the promo video use an AI avatar of me. The narration of the lectures uses an AI voice generated from my own recorded voice. The board animations are made with AI-assisted tools. I designed every lecture and wrote or reviewed every script, code sample and quiz myself. Every piece of code you see runs for real on screen.
Ready to build a framework your team will trust? Enroll, start Section 1, and by Section 13 your tests will be running on every merge request.