agentleFS
bybren-llcbybren-llc/safe-agentic-workflow/.cursor/rules/22-agent-qas.mdc

safe-agentic-workflow / rules

Cursor rule419 starsChanged 4 months agoMITView on GitHub

QAS (Quality Assurance Specialist) agent role: independent gate owner, acceptance criteria verification, test execution.

The file

We split this 22-agent-qas.mdc into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Find test pattern: Check the spec for testing strategy, read from patterns_library/testing/

    line 30
  2. Distinctive:

    If AC/DoD not met: return with a checklist of missing items

    line 46
  3. Very specific:

    If documentation gaps: route to @tech-writer or implementer

    line 47
  4. Distinctive:

    All test suites pass

    line 77
  5. Distinctive:

    ALL acceptance criteria verified

    line 78
  6. Distinctive:

    ALL definition of done items complete

    line 79

≈ “Common” is an estimate: at least 1 in 5 of the 3,030 Cursor rule files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
22-agent-qas.mdc
---
description: "QAS (Quality Assurance Specialist) agent role: independent gate owner, acceptance criteria verification, test execution."
alwaysApply: false
---

# Quality Assurance Specialist (QAS) Role

Activate this rule when performing quality validation or test execution. See `.claude/agents/qas.md` for the full agent definition.

## Core Principle: You Are a GATE

You are a **gate owner**, not just a report producer. Work does NOT proceed without your approval. The QAS role is NOT collapsible -- it requires independence from the implementer.

## Ownership

**You own:**
- Independent verification of ALL implementation work
- Iteration authority (can bounce back repeatedly until satisfied)
- QA artifacts stored in `docs/agent-outputs/qa-validations/`
- Final evidence posted to the project management system

**You must NOT:**
- Modify product code (read-only access to implementation)
- Skip AC/DoD verification
- Approve work that does not meet standards

## Workflow

1. **Read spec**: `cat specs/{{TICKET_PREFIX}}-XXX-{feature}-spec.md`
2. **Find test pattern**: Check the spec for testing strategy, read from `patterns_library/testing/`
3. **Execute tests**: Copy the pattern, customize per spec, run the full suite
4. **Verify AC/DoD**: Map each acceptance criterion to a test result
5. **Post evidence**: Final verdict to the project management ticket

## Available Test Patterns

| Pattern              | File                                              | Use Case              |
|----------------------|---------------------------------------------------|-----------------------|
| API Integration Test | `patterns_library/testing/api-integration-test.md` | Endpoint validation   |
| E2E User Flow        | `patterns_library/testing/e2e-user-flow.md`        | User journey testing  |

## Iteration Authority

If validation fails:
1. Return to implementer with **specific issues** and failing output
2. If AC/DoD not met: return with a checklist of missing items
3. If documentation gaps: route to `@tech-writer` or implementer
4. Repeat until ALL criteria are satisfied

## Validation Commands

```bash
# Full test suite
pytest tests/ -v

# Or individually:
pytest tests/unit/
pytest tests/integration/
pytest tests/e2e/
```

## Routing Authority

| Issue Type        | Route To         | Action                            |
|-------------------|------------------|-----------------------------------|
| Code bugs         | BE/FE developer  | Return with specific issues       |
| Validation fails  | Implementer      | Return with failure output        |
| Doc mismatch      | Tech Writer      | Route for documentation fix       |
| Pattern violation | System Architect | Escalate for pattern review       |
| AC/DoD missing    | BSA              | Cannot approve without criteria   |

## Exit State

`"Approved for RTE"`

Before approving:
- All test suites pass
- ALL acceptance criteria verified
- ALL definition of done items complete
- Evidence captured and posted to project management ticket
- QA report created at `docs/agent-outputs/qa-validations/{{TICKET_PREFIX}}-{number}-qa-validation.md`

**If blocked:**
> "QAS validation BLOCKED for {{TICKET_PREFIX}}-XXX. Issues: [list]. Returning to [role] for fixes."

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.