Interview Insights · Playwright
Why Playwright Questions Reveal More Than Any Resume Line
Quick summary — Playwright resume claims
A resume line tells me what you want me to believe; a Playwright follow-up tells me what you actually did. Resume bullets for automation testers look very similar to each other. The difference shows up one question deeper. When I ask how your page objects receive the page, how you seeded test data, or how long your suite took in CI, builders answer with specifics and problems they hit. People who copied a framework answer with definitions. This page shows the probes I use and how to prepare proof for each line you write.
In this guide you will learn:
- The probe questions behind common Playwright resume claims
- What a real Page Object Model in Playwright looks like
- How custom fixtures show framework maturity
- How to back an API testing claim with the request fixture
- A worksheet to turn each resume line into a story with proof
SECTION 01What a Playwright resume line cannot tell me
When I read a resume, I treat each automation bullet as a hypothesis. 'Automated end-to-end tests using Playwright' could mean you designed a suite, maintained someone else's, or followed a tutorial over a weekend. All three are fine at different levels, but I need to know which one it is, and the resume does not say.
So I ask questions that only make sense if you did the work. Not trick questions. Simple, specific ones that a builder answers in seconds and a copier struggles with. Here are the probes I use most for common claims.
| Resume claim | My probe question | Builder's answer includes | Copier's answer sounds like |
|---|---|---|---|
| Built framework using POM | How does your page object get the page? | Constructor takes Page, locators as fields | POM means separating pages and tests |
| Cross-browser testing | How did you run on Firefox and WebKit? | projects in config, one bug that differed | Playwright supports all browsers |
| Integrated with CI/CD | How long did the suite take and why? | Workers, sharding, slowest test fixed | It ran on every commit |
| API and UI automation | How did UI tests get their data? | request fixture, seeding and cleanup | We used Postman as well |
Me: Your resume says you built a POM framework in Playwright.
How does a page object get access to the page?
Candidate A: POM is a design pattern where each page has a class
and the tests call methods. It improves reusability.
Candidate B: Each class takes the Page in its constructor and
defines locators as readonly fields. Tests get the
page objects through a custom fixture, so no test
calls 'new LoginPage(page)' itself.
Both claimed the same line. Only one answered the question.If the first answer is good, I go one level deeper:
- Do your page object methods contain assertions? Why or why not?
- What did you do when two pages shared a header component?
- How did you name tests so failures were readable in the report?
- Which test was slowest, and what did you do about it?
- What would you change if you rebuilt the framework today?
There are no single right answers here.
I am listening for reasons and real problems.
The last probe, 'what would you change today?', is my favourite. People who built something always have a regret: a fixture they would split, a folder structure they would flatten, a test they would delete. People who did not build it usually say 'nothing, it was good'.
SECTION 02Proving a POM claim: page objects plus fixtures
The Page Object Model claim is the most common and the easiest to probe. In Playwright, a clean page object takes a Page in its constructor, keeps locators as fields and exposes actions in the language of the business: login(), addToCart(), checkout(). A mature framework then hands page objects to tests through custom fixtures created with test.extend, so tests stay short and setup lives in one place.
If you can show this pattern and explain why each piece exists, the POM line on your resume is defended. If you can also explain where you kept assertions and why, you are ahead of most candidates.
| Design choice | Option A | Option B | What I want to hear |
|---|---|---|---|
| Where locators live | Inside each method | As readonly fields in the class | Fields, so they are defined once and easy to update |
| Assertions | Inside page objects | In the test file | Mostly in tests, so the test shows what it checks |
| Creating page objects | new LoginPage(page) in every test | Custom fixture via test.extend | Fixture, so setup is shared and tests stay readable |
| Shared components | Copy header code into every page | A separate component class | Component class reused by pages |
import { type Page, type Locator } from '@playwright/test';
export class LoginPage {
readonly email: Locator;
readonly password: Locator;
readonly submit: Locator;
readonly error: Locator;
constructor(private readonly page: Page) {
this.email = page.getByLabel('Email');
this.password = page.getByLabel('Password');
this.submit = page.getByRole('button', { name: 'Sign in' });
this.error = page.getByRole('alert');
}
async goto() {
await this.page.goto('/login');
}
async login(email: string, password: string) {
await this.email.fill(email);
await this.password.fill(password);
await this.submit.click();
}
}// fixtures.ts
import { test as base } from '@playwright/test';
import { LoginPage } from './pages/LoginPage';
type Pages = { loginPage: LoginPage };
export const test = base.extend<Pages>({
loginPage: async ({ page }, use) => {
const loginPage = new LoginPage(page);
await loginPage.goto();
await use(loginPage);
},
});
export { expect } from '@playwright/test';
// login.spec.ts
import { test, expect } from './fixtures';
test('wrong password shows an error', async ({ loginPage }) => {
await loginPage.login('asha@test.com', 'wrong-pass');
await expect(loginPage.error).toHaveText('Invalid email or password');
});
The Pages type passed to base.extend is what makes loginPage fully typed inside tests, so your editor autocompletes its methods. If an interviewer asks how fixtures stay type-safe, that generic is the answer.
Notice the assertion sits in the test, while the page object only exposes the error locator. When the test fails, the report shows the business check that broke. That is the reasoning I hope to hear.
SECTION 03Proving API and CI claims with specifics
Two more lines often sit together: 'API and UI automation' and 'integrated with CI'. To defend the first, show that your UI tests used the API for setup. Playwright's built-in request fixture can create a user or an order in milliseconds, so the UI test only covers the screen it is about. To defend the second, know how your suite ran in the pipeline: how many workers, whether you sharded, how long it took and where the report went.
Numbers here should be your own and honest. 'Around twelve minutes on two shards' is a fine answer if it is true. If you do not remember, say what you would check to find out.
| Claim | Proof to prepare | Command or API | Common weak spot |
|---|---|---|---|
| API testing | One API test and one API-seeded UI test | request.post, expect(res).toBeOK() | Only ever used Postman manually |
| Parallel runs | How workers were set and why | workers in config, --workers flag | Tests sharing one account |
| CI sharding | How the suite was split across machines | npx playwright test --shard=1/2 | Not knowing what a shard is |
| Reporting | Where failures were read | HTML report, traces as CI artefacts | No idea how failures were reviewed |
import { test, expect } from '@playwright/test';
test('cancelled order shows in history', async ({ page, request }) => {
// Arrange through the API: fast and reliable
const res = await request.post('/api/orders', {
data: { sku: 'MUG-01', qty: 1 },
});
await expect(res).toBeOK();
const { id } = await res.json();
const cancel = await request.post(`/api/orders/${id}/cancel`);
await expect(cancel).toBeOK();
// Act and assert through the UI: what this test is about
await page.goto('/orders/history');
const row = page.getByRole('row').filter({ hasText: String(id) });
await expect(row.getByRole('cell', { name: 'Cancelled' })).toBeVisible();
});# run everything with the HTML report
npx playwright test --reporter=html
# run one project (browser) only
npx playwright test --project=firefox
# set worker count for this run
npx playwright test --workers=4
# split the suite across 2 CI machines
npx playwright test --shard=1/2 # on machine 1
npx playwright test --shard=2/2 # on machine 2
# run tests whose title matches a pattern
npx playwright test -g "cancelled order"
# open the last HTML report
npx playwright show-report
The request fixture uses the same baseURL as the page and, when configured, the same storage state, so authenticated API calls work without extra code. Mentioning that small detail tells me you have actually wired it up.
SECTION 04Worksheet: back every Playwright resume line with proof
Take each automation bullet on your resume and run it through this worksheet. If you cannot fill a row, either build the missing proof in a practice project or soften the bullet so it matches what you really did.
RESUME LINE: ______________________________________
What I personally did (not the team): _______________
One file I can show or describe: _______________
One decision I made and why: _______________
One problem I hit and how I fixed it: _______________
One thing I would change today: _______________
Number I can defend (if any): _______________
If 3 or more blanks remain -> rewrite or remove the line.BEFORE: Built robust Playwright framework with POM and CI.
AFTER: Wrote Playwright (TypeScript) tests for login, cart and
checkout on a practice store using page objects and
custom fixtures; ran them on GitHub Actions with traces
on retry.
BEFORE: Performed API and UI automation.
AFTER: Used Playwright's request fixture to create orders via
API so UI tests only covered the order history screen.
The AFTER lines are longer but every word can be probed.ASK A FRIEND TO READ YOUR RESUME AND ASK:
1. Show me how your page object gets the page.
2. Where do your assertions live and why?
3. How did your UI tests get their data?
4. How long did the suite take in CI?
5. What was the flakiest test and what did you do?
6. What would you rebuild?
Answer each in under 45 seconds.
If you hesitate on one, that line needs more proof.
SECTION 05Habits that make your resume and answers match
The goal is simple: nothing on paper should surprise you in the room.
- Write 'I', then check it — For each bullet, ask whether you did it or your team did. Claim your part clearly and describe the team part honestly.
- Keep a project open on your laptop — In online interviews, being able to share a real page object or config file settles many questions in seconds.
- Prefer specific over impressive — 'Tests for checkout on a practice store' beats 'robust enterprise framework' because it can survive follow-ups.
- Know your folder structure — Be ready to sketch where tests, pages, fixtures and config live, and why you organised them that way.
- Prepare one regret — Having a thoughtful answer to 'what would you change?' signals ownership better than claiming everything was perfect.
SECTION 06Interview Q&A — Playwright resume claims
Q1How do you implement the Page Object Model in Playwright?
Each page class takes a Page in its constructor and defines its locators as readonly fields, using user-facing locators like getByRole and getByLabel. Methods describe business actions such as login or addToCart. I usually expose page objects to tests through custom fixtures created with test.extend, and keep most assertions in the test files.
Q2Why use custom fixtures instead of beforeEach in Playwright?
Fixtures are created only when a test asks for them, they can be combined, and they handle setup and teardown in one place around the use call. A big beforeEach runs for every test whether it needs the setup or not. Fixtures keep tests short and make dependencies explicit in the test signature.
Q3How do you use the API to support UI tests in Playwright?
I use the built-in request fixture to create the data a UI test needs, such as a user or an order, and sometimes to clean it up afterwards. It shares the baseURL from the config. This makes UI tests faster and more reliable because they only drive the screens they are actually testing.
Q4What is sharding in Playwright and when do you use it?
Sharding splits a test suite into parts that run on different machines, using the shard option such as 1/2 and 2/2. I use it in CI when the suite is too slow on one machine even with several workers. Workers parallelise within a machine, shards parallelise across machines.
Q5Should page objects contain assertions?
Mostly no. I keep page objects focused on locating elements and performing actions, and put assertions in tests so each test clearly shows what it verifies. Some teams add small helper checks such as expectLoaded, which is acceptable if the team agrees on the convention.
SECTION 07Test yourself — Playwright resume claims quiz
Five questions. No sign-up.
0 / 5Pick an answer to see why it is right or wrong.
SECTION 08Frequently asked questions
How do I write Playwright experience on a fresher resume?
Describe a specific project: the app you tested, the flows you covered, the patterns you used such as page objects and fixtures, and how you ran the tests. Avoid vague words like robust or enterprise. Every phrase should be something you can explain with an example.
What Playwright questions are asked based on the resume?
Interviewers usually pick a claim and go one level deeper: how your page objects are built, how you handled login and test data, how tests ran in CI, how long they took, and what problems you faced. Prepare a short, honest story for each claim.
Is it okay to list Playwright if I only used it in a course project?
Yes, as long as you describe it accurately as a course or personal project and can explain the code. Interviewers respect honest practice projects far more than inflated claims that collapse under follow-up questions.
Do interviewers check GitHub projects for Playwright?
Many do, especially for freshers. A clean repository with a readable config, page objects, a few independent tests and a short README can support your resume strongly. Make sure secrets are not committed.
What is the difference between workers and shards in Playwright?
Workers are parallel processes on one machine, each running tests in its own browser. Shards split the whole suite across several machines. You can use both together in CI for large suites.
Is there a course that covers Playwright interview questions?
Yes. Uncodemy's Automation Testing Training Course in Noida (classroom and online) includes live projects, one-to-one mock interviews and resume reviews, so you practise Playwright interview questions with trainer feedback before the real interview. You can book a free demo class from this page to see how the sessions work.
SECTION 09Related reads
Classroom & online · Noida
Build Playwright proof that survives any follow-up
Our Automation Testing Training Course guides you through a full Playwright framework with page objects, fixtures, API seeding and CI, so every line on your resume is backed by real work.
Talk to a counsellor for current fees- Framework you build yourself
- Resume review sessions
- API and UI automation
- Mock probing interviews