Execute comprehensive role-based E2E testing with Playwright, testing all user flows for each role
View on GitHubmwguerra/claude-code-plugins
e2e-test-specialist
February 1, 2026
Select agents to install to:
npx add-skill https://github.com/mwguerra/claude-code-plugins/blob/main/e2e-test-specialist/skills/e2e-role-test/SKILL.md -a claude-code --skill e2e-role-testInstallation paths:
.claude/skills/e2e-role-test/# E2E Role-Based Testing Skill ## Overview This skill executes comprehensive role-based E2E testing using Playwright MCP. It tests all pages and flows for each user role, verifying proper access control and role-specific functionality. ## Standard Test Plan Location **Plan file**: `tests/e2e-test-plan.md` This skill reads role definitions and test credentials from the test plan at `tests/e2e-test-plan.md`. If the plan file doesn't exist, the calling command should invoke the `e2e-test-plan` skill first to generate it. ## Purpose Ensure that: - Each user role can access appropriate resources - Unauthorized access is properly blocked - Role-specific features work correctly - Cross-role security is maintained ## Workflow ### Step 0: Test Plan Verification (REQUIRED FIRST) **CRITICAL**: Before testing roles, verify the test plan exists. 1. **Check for Test Plan** - Look for `tests/e2e-test-plan.md` - If the file exists, read the "User Roles" and "Test Credentials" sections - If the file does NOT exist, STOP and report that the plan must be generated first 2. **Read Role Information from Plan** - Extract role names and descriptions - Extract test credentials for each role - Extract role-resource access matrix - Use this information for testing ### Step 1: Prepare Role Testing 1. **Identify All Roles** - List all user roles in the system - Note the role hierarchy - Map permissions per role 2. **Prepare Test Users** - Identify login credentials for each role - Ensure test users exist - Note any role-switching mechanisms 3. **Map Role-Resource Matrix** ``` | Resource | Guest | User | Admin | |----------|-------|------|-------| | /home | Yes | Yes | Yes | | /dashboard | No | Yes | Yes | | /admin | No | No | Yes | ``` ### Step 2: Guest Role Testing **Test unauthenticated access:** 1. **Public Pages** ``` browser_navigate to each public page browser_snapshot to verify content Confirm: Pa