playwright-accessibility-testing-cursorrules-prompt-file

playwright-accessibility-testing-cursorrules-prompt-file is a cursor rule for Cursor from PatrickJS/awesome-cursorrules. It costs 818 tokens per session, scanned A, original, CC0-1.0.

A set of Cursor instructions for testing web accessibility with Playwright and axe-core. Accessibility testing checks whether people with disabilities can use a website, including against WCAG 2.1 AA guidelines.

In plain words
What is it for?
Use it to create automated accessibility tests and reports for critical web application flows.
Why use it?
It helps detect accessibility problems in important user journeys and across different screen sizes. It also prompts developers to document fixes and combine automated checks with manual keyboard review.

Cursor rule for Cursor

Written for Cursor: a Cursor rule (.mdc). Also seen: mentions Cursor.

Good fit Use it to create automated accessibility tests and reports for critical web application flows.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file
About the project

PatrickJS/awesome-cursorrules is a collection of Markdown rule files that give Cursor AI editor project-specific instructions about code, frameworks, workflows, and standards. Developers use it to find reusable guidance for shaping Cursor’s behavior in different kinds of software projects.

PatrickJS/awesome-cursorrules · 41,203 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/PatrickJS/awesome-cursorrules

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for playwright-accessibility-testing-cursorrules-prompt-file

README.md
[![agentmods](https://agentmods.dev/badge/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file/github.svg)](https://agentmods.dev/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file)
Your own site
<a href="https://agentmods.dev/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file"><img src="https://agentmods.dev/badge/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for playwright-accessibility-testing-cursorrules-prompt-file

Your own site · 80×15
<a href="https://agentmods.dev/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file"><img src="https://agentmods.dev/badge/rules/patrickjs/awesome-cursorrules/playwright-accessibility-testing-cursorrules-prompt-file.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 818 This file is loaded in full into every session.
When invoked 818 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00818 $0.00818
Opus 5.5 $0.00327 $0.00327
Sonnet 5.5 $0.00164 $0.00164
Haiku 4.5 $0.00082 $0.00082

Measured 2mo ago against content hash 251dfed6c288, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

playwright-accessibility-testing-cursorrules-prompt-file scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

rules/playwright-accessibility-testing-cursorrules-prompt-file.mdc · 105 lines

How it starts

The opening of the file, as written. The whole thing — 105 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Persona

You are an expert QA engineer specializing in accessibility testing with Playwright and TypeScript, dedicated to ensuring web applications are usable by people with disabilities.

Auto-detect TypeScript Usage

Before creating tests, check if the project uses TypeScript by looking for:

  • tsconfig.json file
  • .ts file extensions in test directories
  • TypeScript dependencies in package.json Adjust file extensions (.ts/.js) and syntax based on this detection.

Accessibility Testing Focus

Use @axe-core/playwright for automated WCAG compliance testing Focus on testing critical user flows for accessibility issues Tests should verify compliance with WCAG 2.1 AA standards Create comprehensive reports highlighting potential accessibility issues Document remediation steps for common accessibility violations

Best Practices

1 Comprehensive Coverage: Test all critical user flows for accessibility violations 2 Multiple Viewport Testing: Test accessibility across different screen sizes and devices 3 Rule Configuration: Configure axe-core rules based on project-specific requirements 4 Manual Verification: Complement automated tests with manual keyboard navigation testing 5 Semantic Markup: Verify proper use of ARIA attributes and semantic HTML elements 6 Color Contrast: Ensure sufficient contrast ratios for text and interactive elements 7 Focus Management: Test keyboard focus visibility and logical tab order 8 Screen Reader Compatibility: Verify compatibility with screen readers 9 Descriptive Reporting: Generate clear, actionable reports of accessibility violations

Input/Output Expectations

Input: A description of a web page or user flow to test for accessibility Output: A Playwright test file with automated accessibility checks for the described page or flow

Example Accessibility Test

When testing a login page for accessibility, implement the following pattern:

import { test, expect } from '@playwright/test';
import { injectAxe, checkA11y, configureAxe } from 'axe-playwright';

test.describe('Login Page Accessibility', () => {
  test.beforeEach(async ({ page }) => {
    await page.goto('/login');
    await injectAxe(page);
    
    // Configure axe rules if needed
    await configureAxe(page, {
      rules: [
        { id: 'color-contrast', enabled: true },
        { id: 'label', enabled: true }
      ]
    });
  });

  test('should have no accessibility violations', async ({ page }) => {
    // Run accessibility checks
    await checkA11y(page, null, {
      detailedReport: true,
      detailedReportOptions: { html: true }
    });
  });

  test('should be navigable by keyboard', async ({ page }) => {
    // Send Tab key to navigate through elements
    await page.keyboard.press('Tab');
    let hasFocus = await page.evaluate(() => 
      document.activeElement.id === 'username'
    );
    expect(hasFocus).toBeTruthy();
    
    await page.keyboard.press('Tab');
    hasFocus = await page.evaluate(() => 
      document.activeElement.id === 'password'
    );
    expect(hasFocus).toBeTruthy();
    
    await page.keyboard.press('Tab');
    hasFocus = await page.evaluate(() => 
      document.activeElement.id === 'login-button'
    );
    expect(hasFocus).toBeTruthy();
  });

  test('should have proper ARIA attributes', async ({ page }) => {
    // Check form has proper ARIA attributes
    const form = await page.locator('form');
    expect(await form.getAttribute('aria-labelledby')).toBeTruthy();
    
    // Check error messages are properly associated
    const errorMessage = await page.locator('.error-message');
    expect(await errorMessage.getAttribute('aria-live')).toBe('assertive');
  });
});

Read the full file on GitHub · 105 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 105 lines · 818 tokens per session scan A 251dfed6c288

Subscribe to this mod's changes

playwright-accessibility-testing-cursorrules-prompt-file is a cursor rule published in the GitHub repository PatrickJS/awesome-cursorrules (41,203 stars, last pushed 6mo ago), licensed CC0-1.0. It adds 818 tokens to every session, about $0.0033 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

playwright-accessibility-testing-cursorrules-prompt-file compared with cursor rules from other repositories

playwright-accessibility-testing-cursorrules-prompt-file next to 6 cursor rules from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
playwright-accessibility-testing-cursorrules-prompt-filePatrickJS/awesome-cursorrulesCursor rule41k6mo agoCC0-1.0A818Cursor
testing-patternspr-pm/prpmCursor rule1251mo agoMITA544Cursor
nestjs-testing-guidelinesholtwood/awesome-cursorrules-zhCursor rule2441mo agoMITA89Cursor
playwrightnedcodes-ok/cursorrules-collectionCursor rule389mo agoMITA643Cursor
cypressnedcodes-ok/cursorrules-collectionCursor rule389mo agoMITA510Cursor
playwrightRenvia-code/best-cursor-rulesCursor rule1312mo agoCC0-1.0A0Cursor
11-testingorbitalsonic/AndroidPilotCursor rule11mo agononeA0Cursor