Playwright E2E testing specialist for writing maintainable browser tests, debugging flaky tests, and CI/CD integration.
Works with
Emphasizes role-based selectors and auto-waiting to avoid brittle tests and arbitrary timeouts
Provides Page Object Model patterns for test organization, fixture setup, and configuration guidance
Includes debugging workflow using trace viewer, screenshots, and retry strategies to identify and fix flaky tests
Covers API mocking, visual regression testing, and para
AI-first code editor with Composer
Before installing skills in Cursor, ensure your development environment meets these requirements:
node --versionplaywright-expertExecute the skills CLI command in your project's root directory to begin installation:
Fetches playwright-expert from jeffallan/claude-skills and configures it for Cursor.
The CLI shows a list of agents. Use arrow keys and space to select Cursor:
Confirm successful installation by checking the skill directory location:
Restart Cursor to activate playwright-expert. Access via /playwright-expert in your agent's command palette.
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Submit your Claude Code skill and start earning
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
Save 3-5 hours per week on routine tasks
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
Accelerate learning and skill development by 2x
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
Improve work quality by 30-40% with less effort
1
total installs
1
this week
7.9K
GitHub stars
0
upvotes
Run in your terminal
1
installs
1
this week
7.9K
stars
E2E testing specialist with deep expertise in Playwright for robust, maintainable browser automation.
Load detailed guidance based on context:
| Topic | Reference | Load When |
|---|---|---|
| Selectors | references/selectors-locators.md |
Writing selectors, locator priority |
| Page Objects | references/page-object-model.md |
POM patterns, fixtures |
| API Mocking | references/api-mocking.md |
Route interception, mocking |
| Configuration | references/configuration.md |
playwright.config.ts setup |
| Debugging | references/debugging-flaky.md |
Flaky tests, trace viewer |
waitForTimeout() (use proper waits)first(), nth() without good reason// ✅ Role-based selector — resilient to styling changes
await page.getByRole('button', { name: 'Submit' }).click();
await page.getByLabel('Email address').fill('[email protected]');
// ❌ CSS class selector — breaks on refactor
await page.locator('.btn-primary.submit-btn').click();
await page.locator('.email-input').fill('[email protected]');
// pages/LoginPage.ts
import { type Page, type Locator } from '@playwright/test';
export class LoginPage {
readonly page: Page;
readonly emailInput: Locator;
readonly passwordInput: Locator;
readonly submitButton: Locator;
readonly errorMessage: Locator;
constructor(page: Page) {
this.page = page;
this.emailInput = page.getByLabel('Email address');
this.passwordInput = page.getByLabel('Password');
this.submitButton = page.getByRole('button', { name: 'Sign in' });
this.errorMessage = page.getByRole('alert');
}
async goto() {
await this.page.goto('/login');
}
async login(email: string, password: string) {
await this.emailInput.fill(email);
await this.passwordInput.fill(password);
await this.submitButton.click();
}
}
// tests/login.spec.ts
import { test, expect } from '@playwright/test';
import { LoginPage } from '../pages/LoginPage';
test.describe('Login', () => {
let loginPage: LoginPage;
test.beforeEach(async ({ page }) => {
loginPage = new LoginPage(page);
await loginPage.goto();
});
test('successful login redirects to dashboard', async ({ page }) => {
await loginPage.login('[email protected]', 'correct-password');
await expect(page).toHaveURL('/dashboard');
});
test('invalid credentials shows error', async () => {
await loginPage.login('[email protected]', 'wrong-password');
await expect(loginPage.errorMessage).toBeVisible();
await expect(loginPage.errorMessage).toContainText('Invalid credentials');
});
});
// 1. Run failing test with trace enabled
// playwright.config.ts
use: {
trace: 'on-first-retry',
screenshot: 'only-on-failure',
}
// 2. Re-run with retries to capture trace
// npx playwright test --retries=2
// 3. Open trace viewer to inspect timeline
// npx playwright show-trace test-results/.../trace.zip
// 4. Common fix — replace arbitrary timeout with proper wait
// ❌ Flaky
await page.waitForTimeout(2000);
await page.getByRole('button', { name: 'Save' }).click();
// ✅ Reliable — waits for element state
await page.getByRole('button', { name: 'Save' }).waitFor({ state: 'visible' });
await page.getByRole('button', { name: 'Save' }).click();
// 5. Verify fix — run test 10x to confirm stability
// npx playwright test --repeat-each=10
When implementing Playwright tests, provide:
Playwright, Page Object Model, auto-waiting, locators, fixtures, API mocking, trace viewer, visual comparisons, parallel execution, CI/CD integration
Prerequisites
Time Estimate
15-45 minutes depending on use case complexity
Steps
Common Pitfalls
✓ Do
✗ Don't
💡 Pro Tips
✓ Use when
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
✗ Avoid when
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
jeffallan/claude-skills
jeffallan/claude-skills
jeffallan/claude-skills
jeffallan/claude-skills
jeffallan/claude-skills
jeffallan/claude-skills
We added playwright-expert from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.
playwright-expert fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.
playwright-expert is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
I recommend playwright-expert for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.
Useful defaults in playwright-expert — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
Registry listing for playwright-expert matched our evaluation — installs cleanly and behaves as described in the markdown.
Keeps context tight: playwright-expert is the kind of skill you can hand to a new teammate without a long onboarding doc.
Keeps context tight: playwright-expert is the kind of skill you can hand to a new teammate without a long onboarding doc.
Registry listing for playwright-expert matched our evaluation — installs cleanly and behaves as described in the markdown.
playwright-expert has been reliable in day-to-day use. Documentation quality is above average for community skills.
showing 1-10 of 59