Playwright Best Practices
Use when writing Playwright tests, fixing flaky tests, debugging failures, implementing Page Object Model, configuring CI/CD, optimizing performance, mocking APIs, handling authentication or OAuth, testing accessibility (axe-core), file uploads/downloads, date/time mocking, WebSockets, geolocation, permissions, multi-tab/popup flows, mobile/responsive layouts, touch gestures, GraphQL, error handling, offline mode, multi-user collaboration, third-party services (payments, email verification), console error monitoring, global setup/teardown, test annotations (skip, fixme, slow), test tags (@smoke, @fast, @critical, filtering with --grep), project dependencies, security testing (XSS, CSRF, auth), performance budgets (Web Vitals, Lighthouse), iframes, component testing, canvas/WebGL, service workers/PWA, test coverage, i18n/localization, Electron apps, or browser extension testing. Covers E2E, component, API, visual, accessibility, security, Electron, and extension testing.
- Skill ID
- currents-dev/playwright-best-practices-skill/playwright-best-practices
- Publisher
- currents-dev
- Repository
- playwright-best-practices-skill
- Installs
- 375
- Files
- 59
- License
- MIT
- Synced
- Sep 16, 2026
Open any RiverX project, open the Skills panel in the chat, and search for this identifier. The files are fetched from the source repository at install time.
currents-dev/playwright-best-practices-skill/playwright-best-practicesInstalls these files- SKILL.md
- advanced/authentication-flows.md
- advanced/authentication.md
- advanced/clock-mocking.md
- advanced/mobile-testing.md
- advanced/multi-context.md
- advanced/multi-user.md
- advanced/network-advanced.md
- advanced/third-party.md
- architecture/pom-vs-fixtures.md
- architecture/test-architecture.md
- architecture/when-to-mock.md
- browser-apis/browser-apis.md
- browser-apis/iframes.md
- browser-apis/service-workers.md
- browser-apis/websockets.md
- core/annotations.md
- core/assertions-waiting.md
- core/configuration.md
- core/fixtures-hooks.md
- core/global-setup.md
- core/locators.md
- core/page-object-model.md
- core/projects-dependencies.md
- core/test-data.md
- core/test-suite-structure.md
- core/test-tags.md
- debugging/console-errors.md
- debugging/debugging.md
- debugging/error-testing.md
- debugging/flaky-tests.md
- frameworks/angular.md
- frameworks/nextjs.md
- frameworks/react.md
- frameworks/vue.md
- infrastructure-ci-cd/ci-cd.md
- infrastructure-ci-cd/docker.md
- infrastructure-ci-cd/github-actions.md
- infrastructure-ci-cd/gitlab.md
- infrastructure-ci-cd/other-providers.md
- infrastructure-ci-cd/parallel-sharding.md
- infrastructure-ci-cd/performance.md
- infrastructure-ci-cd/reporting.md
- infrastructure-ci-cd/test-coverage.md
- testing-patterns/accessibility.md
- testing-patterns/api-testing.md
- testing-patterns/browser-extensions.md
- testing-patterns/canvas-webgl.md
- testing-patterns/component-testing.md
- testing-patterns/drag-drop.md
- testing-patterns/electron.md
- testing-patterns/file-operations.md
- testing-patterns/file-upload-download.md
- testing-patterns/forms-validation.md
- testing-patterns/graphql-testing.md
- testing-patterns/i18n.md
- testing-patterns/performance-testing.md
- testing-patterns/security-testing.md
- testing-patterns/visual-regression.md
What this skill tells the agent
Playwright Best Practices
This skill provides comprehensive guidance for all aspects of Playwright test development, from writing new tests to debugging and maintaining existing test suites.
Activity-Based Reference Guide
Consult these references based on what you're doing:
Writing New Tests
When to use: Creating new test files, writing test cases, implementing test scenarios
| Activity | Reference Files |
|---|---|
| Writing E2E tests | test-suite-structure.md, locators.md, assertions-waiting.md |
| Writing component tests | component-testing.md, test-suite-structure.md |
| Writing API tests | api-testing.md, test-suite-structure.md |
| Writing GraphQL tests | graphql-testing.md, api-testing.md |
| Writing visual regression tests | visual-regression.md, canvas-webgl.md |
| Structuring test code with POM | page-object-model.md, test-suite-structure.md |
| Setting up test data/fixtures | fixtures-hooks.md, test-data.md |
| Handling authentication | authentication.md, authentication-flows.md |
| Testing date/time features | clock-mocking.md |
| Testing file upload/download | file-operations.md, file-upload-download.md |
| Testing forms/validation | forms-validation.md |
| Testing drag and drop | drag-drop.md |
| Testing accessibility | accessibility.md |
| Testing security (XSS, CSRF) | security-testing.md |
| Using test annotations | annotations.md |
| Using test tags | test-tags.md |
| Testing iframes | iframes.md |
| Testing canvas/WebGL | canvas-webgl.md |
| Internationalization (i18n) | i18n.md |
| Testing Electron apps | electron.md |
| Testing browser extensions | browser-extensions.md |
Mobile & Responsive Testing
When to use: Testing mobile devices, touch interactions, responsive layouts
| Activity | Reference Files |
|---|---|
| Device emulation | mobile-testing.md |
| Touch gestures (swipe, tap) | mobile-testing.md |
| Viewport/breakpoint testing | mobile-testing.md |
| Mobile-specific UI | mobile-testing.md, locators.md |
Real-Time & Browser APIs
When to use: Testing WebSockets, geolocation, permissions, multi-tab flows
| Activity | Reference Files |
|---|---|
| WebSocket/real-time testing | websockets.md |
| Geolocation mocking | browser-apis.md |
| Permission handling | browser-apis.md |
| Clipboard testing | browser-apis.md |
| Camera/microphone mocking | browser-apis.md |
| Multi-tab/popup flows | multi-context.md |
| OAuth popup handling | third-party.md, multi-context.md |
Debugging & Troubleshooting
When to use: Test failures, element not found, timeouts, unexpected behavior
| Activity | Reference Files |
|---|---|
| Debugging test failures | debugging.md, assertions-waiting.md |
| Fixing flaky tests | flaky-tests.md, debugging.md, assertions-waiting.md |
| Debugging flaky parallel runs | flaky-tests.md, performance.md, fixtures-hooks.md |
