Basic Form Elements
Practise filling text, password, email, phone inputs and a textarea, then submitting and resetting a real form.
Button Interactions
Practise single click, double click, right click, disabled buttons, a button that enables after 3s, and a self-relabelling button.
Checkboxes & Radio Buttons
Practise toggling checkboxes, a select-all that controls them, radio groups, and a checkbox that reveals hidden text.
Colors (Checkboxes)
Select Preference (Radio Buttons)
Dynamic Visibility Toggle
Dropdowns
Practise standard select, multi-select, a custom div-based dropdown, and a select populated from state.
Locator Practice
One element per common locator strategy plus a deeply nested tree for XPath axis practice.
Deeply nested structure for XPath axes:
Dynamic Content
Practise waiting for elements to appear/disappear, text changes, a counter, and dynamically injected content.
Waits & Synchronisation
Practise explicit waits: a spinner that becomes Loaded, delayed text, an animated progress bar, and a delayed AJAX response.
âŗ Spinner Wait
đŦ Delayed Text Value
đ Animated Progress Bar
⥠AJAX Delay Simulation
Table Automation
Practise reading rows, sorting by name, filtering with search, and paginating (page size 3).
| ID | Name | Role | Status |
|---|
Alerts
Practise handling native JS dialogs: alert, confirm and prompt.
Modals
Practise opening a modal, closing via the X or close button, and closing by clicking the overlay.
iFrame
Practise switching into an iframe context before interacting with the form inside it.
Shadow DOM
Practise piercing a shadow root: the input and button live inside a custom element's shadow DOM.
Drag & Drop
Practise native HTML5 drag and drop: drag the source onto the drop zone.
Drag Box
Reorderable List
- Item 1
- Item 2
- Item 3
Hover Menu
Practise hovering a menu item to reveal a submenu (Actions class hover/move-to-element).
Tooltip
Practise triggering and reading a tooltip that appears on hover.
File Upload
Practise uploading a file and verifying the selected file name appears.
Drag and drop a file here, or click to browse
Download
Practise triggering a file download (practice.txt) and asserting on the downloaded file.
Hidden Elements
Practise locating elements that are in the DOM but hidden via CSS, and revealing hidden content.
Scroll Testing
Practise scrolling a far-away element into view before asserting on it.
Infinite Scroll List
- Seed Item 1
- Seed Item 2
- Seed Item 3
- Seed Item 4
- Seed Item 5
- Seed Item 6
- Seed Item 7
- Seed Item 8
Multiple Windows
Practise switching between window/tab handles after opening a new one.
Authentication Simulation
Practise a login flow. Demo credentials: username admin, password admin123.
Stale Element Simulation
Practise StaleElementReferenceException: the target node is replaced (new key), so a previously located reference is no longer attached.
Dynamic List
Practise adding and removing items and asserting on the changing list length.
- First item
- Second item
Network Delay Simulation
Practise waiting through a simulated network delay before the response text appears.
Random Fail (Flaky) Elements
Practise handling flaky outcomes: this button passes or fails roughly 50/50 each run.
Keyboard Actions
Practise sending keys: type here and watch the last key; Arrow Up/Down change the counter. Try Enter, Tab and arrows.
Slider
Practise moving a range slider and reading its live value.
Date Picker
Practise selecting a date and asserting the echoed value. Use both the native HTML5 date input and the custom interactive calendar dialog picker.
Custom Calendar Dialog Picker (past dates and dates beyond 60 days out are disabled)
Resizable Element
Practise resizing an element by dragging its bottom-right handle.
Complex DOM Structure
Practise advanced XPath axes and CSS combinators on a deeply nested, multi-sibling tree.
-
Node Group A
- list leaf 1
- list leaf 2
-
Node Group B
- list leaf 3
- list leaf 4
Nested Sibling Actions Table
| Item Row | Identifier | Actions |
|---|---|---|
| Item Alpha | ID-ALPHA | |
| Item Beta | ID-BETA |
Autocomplete / Typeahead
Type in the search field to trigger a live suggestions dropdown. Practice waiting for dynamic options and selecting an item from an async list.
Context Menu (Right-Click)
Right-click the target area to open a custom context menu. Practice using page.click({ button: 'right' }) and selecting menu options.
Clipboard / Copy to Clipboard
Click the copy button to capture the snippet to your clipboard. Practise reading the clipboard with Playwright's page.evaluate() or browser context grants.
npx playwright test --headed --project=chromium
Multi-Step Wizard / Stepper
Navigate a 3-step form wizard: Personal Info â Account Setup â Review. Practice state validation across multiple steps and Next/Back button interactions.
Step 1: Personal Info
Color Picker
Use the native color picker to select a colour. Practice automating input[type=color] using Playwright's page.fill() with hex values like #ff6600.
#3b82f6
Nested iFrames
Practise switching between multiple levels of nested iframes. An outer frame contains an inner frame â you must switch context twice to reach the deepest element.
Nested Tables
Practise navigating complex table structures: a main data table with an expandable nested inner table per row. Use XPath row indexing and CSS nth-child selectors.
| Order ID | Customer | Total | Status | Details |
|---|---|---|---|---|
#ORD-001 |
Alice Johnson | $142.00 | Shipped | |
#ORD-002 |
Bob Martinez | $78.50 | Processing | |
#ORD-003 |
Carol Lee | $219.99 | Cancelled |
Page Operations
Practise page-level interactions: changing document title, reloading/refresh tracking, and handling multiple pages.
Bulk Links Scraper
Practise scraping: identify, iterate, and count 100+ unique links on the page.
Infinite Scroll
Practise infinite scrolling: scroll the container to auto-load new items and verify dynamically added DOM elements.
Search with Debounce
Practise waiting for asynchronous input: the search query triggers matching results after a 500ms pause.
Character API Call Simulation
Practise network interception: typing each character fires a separate simulated API request instantly.
Tabs
Practise switching between tab panels, including a disabled tab that should never become active.
đ¤ Profile settings panel content.
đ Security settings panel content.
đ Notifications settings panel content.
đŗ Billing settings panel content.
Accordion
Practise expanding/collapsing accordion panels â multiple panels can be open at the same time.
Role, text, label, placeholder, alt text, title, test id, and raw CSS/XPath.
Playwright automatically waits for an element to be actionable before interacting with it.
A reusable piece of setup/teardown logic injected into a test.
Toggle / Switch
Practise a checkbox visually rendered as an iOS-style toggle switch â automate it the same way as a checkbox (`.check()`/`.click()`), not by clicking a raw slider pixel.
Toast Notifications
Practise waiting for a transient toast to appear and auto-dismiss after 3 seconds (or dismiss it manually) â an element that exists only briefly.
Dependent Dropdowns
Practise cascading selects: choosing a Country repopulates State, which repopulates City. Each downstream select stays disabled until its parent has a value.
OTP / Verification Code Input
Practise a 6-box OTP input: typing a digit auto-advances focus to the next box; Backspace on an empty box moves focus back. Correct demo code is 123456.
Rich Text Editor
Practise a contenteditable-based editor: select text, apply Bold/Italic/Underline formatting, and read back the resulting HTML â a different automation model than a plain input or textarea.
Tree View
Practise an interactive file-tree: expand/collapse folders, and check a parent node to cascade-select all its children.
Responsive Navigation
A self-contained nav bar that shows full links above a 640px container width, and collapses to a hamburger menu below it. Resize your browser (or use Playwright's setViewportSize) to see it switch.
Popover
Practise a click-triggered popover (unlike Section 15's hover-only tooltip): it stays open until you click its own close button, click outside it, or press Escape.
This popover stays open until dismissed â click outside, press Escape, or use the close button.