pytest-playwright Built-in Fixtures Explained (page, context, browser and more)
Every pytest-playwright fixture explained: the page, context and browser chain, scopes, test isolation, new_context for two users, browser_name and base_url.
Online Learning Platform
Free tutorials, solved practice problems and interview prep for QA and automation engineers: Python, Playwright, Selenium, SQL, Git and more.
Every pytest-playwright fixture explained: the page, context and browser chain, scopes, test isolation, new_context for two users, browser_name and base_url.
Visual testing in Playwright Python: a screenshot comparison fixture with Pillow and pixelmatch, a pytest plugin, and structure checks with ARIA snapshots.
Take page, full-page and element screenshots in Playwright Python, record videos, keep traces on failure with pytest-playwright and use the Trace Viewer.
How Playwright Python auto-waits before actions, plus explicit waits: wait_until, wait_for_url, locator.wait_for, wait_for_function, expect_response, timeouts.
Playwright Python assertions with expect: visibility, state, text, value, attribute and count checks, negation, custom messages, timeouts and expect.soft.
Upload files in Playwright Python with set_input_files, in-memory files and file chooser, and verify downloads with expect_download, save_as and content checks.
Read and verify HTML tables in Playwright Python: headers, rows as dictionaries, find a row by cell, columns by header name, sorting checks and pagination.
Handle JavaScript alert, confirm and prompt dialogs, work inside iframes with frame_locator, and control popups and new tabs in Playwright Python.
Playwright Python actions: click variants, fill vs press_sequentially, keys, check, select_option, dates, hover, drag and drop and actionability.
CSS and XPath selectors in Playwright Python: ids, classes, attributes, combinators, :has-text, :has, :visible, XPath axes and when to prefer get_by_role.
Master Playwright Python locators: get_by_role, get_by_label, get_by_text and get_by_test_id, filtering and chaining, strictness errors and shadow DOM.
Extend pytest for Playwright: install and disable plugins, add a --env option with pytest_addoption, auto-mark tests, and screenshot failures with a hook.
Take free timed mock tests with answers and explanations.