Playwright · Junior · Question 12 of 75
What is the page argument in a Playwright test?
test("opens home", async ({ page }) => {
await page.goto("/");
});- 1A global page shared between all the tests in a file
- 2The source code of the page under test as a string
- 3A fixture with a fresh page in an isolated context
Show the answer
Correct answer: A fixture with a fresh page in an isolated context
Explanation
page is a built-in fixture. Each test gets a new browser context and page, so cookies and storage don't leak between tests.