From eb87094f6c749e504708308bdb8f0a8ee14fc0f6 Mon Sep 17 00:00:00 2001 From: Pranshu Chittora <32242596+pranshuchittora@users.noreply.github.com> Date: Sun, 16 Aug 2026 06:31:48 +0530 Subject: [PATCH 1/2] Add Agent QA testing Cursor rule --- README.md | 1 + rules/agent-qa-testing.mdc | 47 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 rules/agent-qa-testing.mdc diff --git a/README.md b/README.md index 8204dac5..eff29607 100644 --- a/README.md +++ b/README.md @@ -212,6 +212,7 @@ By adding selected `.mdc` files to `.cursor/rules/`, you can use these rules dir ### Testing +- [Agent QA Testing](https://github.com/PatrickJS/awesome-cursorrules/blob/main/rules/agent-qa-testing.mdc) - Evidence-led Agent QA workflows for natural-language test authoring, execution, failure triage, self-heal review, and scoped fixes. - [Cypress API Testing](https://github.com/PatrickJS/awesome-cursorrules/blob/main/rules/cypress-api-testing-cursorrules-prompt-file.mdc) - Cypress development with API testing. - [Cypress Accessibility Testing](https://github.com/PatrickJS/awesome-cursorrules/blob/main/rules/cypress-accessibility-testing-cursorrules-prompt-file.mdc) - Cypress development with accessibility testing. - [Cypress Defect Tracking](https://github.com/PatrickJS/awesome-cursorrules/blob/main/rules/cypress-defect-tracking-cursorrules-prompt-file.mdc) - Cypress development with defect tracking. diff --git a/rules/agent-qa-testing.mdc b/rules/agent-qa-testing.mdc new file mode 100644 index 00000000..d69c58e1 --- /dev/null +++ b/rules/agent-qa-testing.mdc @@ -0,0 +1,47 @@ +--- +description: "Operate Agent QA from Cursor for evidence-led web and mobile testing, result triage, and scoped fixes." +globs: **/* +alwaysApply: false +--- + +# Agent QA Testing + +Use this rule when the user asks to operate [Agent QA](https://github.com/vostride/agent-qa) or the repository already contains a configured Agent QA workspace. Agent QA is an open-source QA agent with a CLI, MCP server, dashboard, and portable Agent Skills. + +## Establish the Integration + +1. Read the repository's testing instructions and locate its Agent QA configuration before running anything. +2. Prefer an already configured Agent QA MCP server. The server command is `agent-qa mcp`. +3. If MCP is unavailable but the package is installed, run `agent-qa --help` and follow the commands exposed by that installed version. Do not invent flags or subcommands. +4. Do not initialize, overwrite, or migrate a workspace unless the user requested it and the resulting file changes are understood. + +## Testing Workflow + +1. Translate the requested behavior into observable user outcomes, including the important success path and a small number of meaningful failure paths. +2. Reuse existing tests and project conventions before creating new coverage. +3. Keep test data deterministic and avoid real production accounts, secrets, payments, or destructive actions. +4. Run the narrowest relevant Agent QA test first. Expand the run only when the initial evidence justifies it. +5. Capture the exact result, failing step, screenshot or trace reference, and relevant console or network evidence. + +## Triage Before Editing + +Classify a failure before changing code or tests: + +- **Product defect**: the application violates the expected user outcome. +- **Test defect**: the test has a stale assumption, selector, assertion, or setup. +- **Environment issue**: the target, dependency, data, credential, device, or browser is unavailable. +- **Inconclusive**: the evidence is insufficient or contradictory. + +Do not label every failed run as a product bug. If Agent QA self-heals a test, inspect the proposed change and confirm that it preserves the intended behavior rather than merely making the test pass. + +## Scoped Fixes + +- Change application code only for an evidenced product defect. +- Change test code only for an evidenced test defect. +- Preserve unrelated behavior and existing repository conventions. +- Ask before broad dependency upgrades, schema changes, destructive data operations, or changes that weaken assertions. +- Re-run the smallest failing test after a fix, then run the relevant surrounding suite when practical. + +## Reporting + +Report the command or MCP operation used, the target environment, observed outcome, evidence, classification, files changed, and validation performed. Distinguish facts from hypotheses and never claim a test passed without a completed result. From f5096662f98a462607fbc40187711b2939ab55e9 Mon Sep 17 00:00:00 2001 From: Pranshu Chittora <32242596+pranshuchittora@users.noreply.github.com> Date: Sun, 16 Aug 2026 07:01:57 +0530 Subject: [PATCH 2/2] Address Agent QA rule review feedback --- rules/agent-qa-testing.mdc | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/rules/agent-qa-testing.mdc b/rules/agent-qa-testing.mdc index d69c58e1..164fd8d2 100644 --- a/rules/agent-qa-testing.mdc +++ b/rules/agent-qa-testing.mdc @@ -1,6 +1,6 @@ --- description: "Operate Agent QA from Cursor for evidence-led web and mobile testing, result triage, and scoped fixes." -globs: **/* +globs: ["agent-qa.config.yaml", "tests/**/*.yaml", "suites/**/*.suite.yaml", "hooks.yaml", ".agent-qa/**/*"] alwaysApply: false --- @@ -11,8 +11,8 @@ Use this rule when the user asks to operate [Agent QA](https://github.com/vostri ## Establish the Integration 1. Read the repository's testing instructions and locate its Agent QA configuration before running anything. -2. Prefer an already configured Agent QA MCP server. The server command is `agent-qa mcp`. -3. If MCP is unavailable but the package is installed, run `agent-qa --help` and follow the commands exposed by that installed version. Do not invent flags or subcommands. +2. Read any existing MCP configuration and use its exact command, arguments, environment, and transport. Do not replace configured values with a guessed `agent-qa mcp` command. +3. If MCP is unavailable but Agent QA is installed locally, identify the repository's package manager and use its local-package runner to invoke `agent-qa --help`. Do not install or download a different version implicitly, and do not invent flags or subcommands. 4. Do not initialize, overwrite, or migrate a workspace unless the user requested it and the resulting file changes are understood. ## Testing Workflow @@ -20,8 +20,9 @@ Use this rule when the user asks to operate [Agent QA](https://github.com/vostri 1. Translate the requested behavior into observable user outcomes, including the important success path and a small number of meaningful failure paths. 2. Reuse existing tests and project conventions before creating new coverage. 3. Keep test data deterministic and avoid real production accounts, secrets, payments, or destructive actions. -4. Run the narrowest relevant Agent QA test first. Expand the run only when the initial evidence justifies it. -5. Capture the exact result, failing step, screenshot or trace reference, and relevant console or network evidence. +4. Redact credentials, authorization headers, cookies, tokens, email addresses, personal data, and other sensitive values from screenshots, traces, console or network evidence, and reports before saving or sharing them. +5. Run the narrowest relevant Agent QA test first. Expand the run only when the initial evidence justifies it. +6. Capture the exact result, failing step, screenshot or trace reference, and relevant console or network evidence. ## Triage Before Editing