| name | sdlc-qa-task |
| version | 1.0.0 |
| description | QA verification for a single task after its PR has been merged. Reads
acceptance criteria from the GSD PLAN.md, checks what was implemented,
logs PASS/FAIL to QA-LOG.md in the active phase directory. Invoke manually
after each PR merge during execute-phase. Usage: /sdlc-qa-task "task name"
|
Verify a specific task from the current GSD phase has been correctly implemented.
Append PASS/FAIL result to QA-LOG.md in the active phase directory.
Step 1: Identify active phase and task
Resolve active phase directory:
Read .planning/STATE.md for the current active phase if present.
If STATE.md is absent, check .planning/sdlc-state.md — look for a line containing <resolved-phase-number>: or phase-number: and use that value.
Otherwise, use the highest-numbered directory prefix by parsing the leading integer (e.g., 03-auth → 3, 10-billing → 10; take the maximum integer).
Record as <current-phase>.
Identify task:
If the user provided a task name/description in the invocation, use it.
If not, list all tasks found in .planning/phases/<current-phase>/ PLAN.md files and ask: "Which task should I QA? Provide the task name or description."
Step 2: Read acceptance criteria
Read all PLAN.md files in .planning/phases/<current-phase>/ (e.g., 01-01-PLAN.md).
First, attempt exact case-insensitive match on task heading text. If zero matches, attempt substring match and list all candidates, asking the user to confirm. If multiple exact matches exist, list them with line numbers and ask the user to disambiguate.
Extract:
- Task description (exact text)
- Acceptance criteria / definition of done (every bullet point)
- Files listed as expected to be created or modified
If task is not found in PLAN.md, tell the user: "Task '[name]' not found in PLAN.md. Check the task name and try again."
If the task is found but contains no acceptance criteria bullets, report to the user: "Task found but has no acceptance criteria defined. Cannot verify. Please add criteria to PLAN.md before running QA." Do not write to QA-LOG.md.
Step 3: Verify implementation
For each acceptance criterion, check the codebase:
- Read the relevant source files
- Look for the specific behavior/feature described
- Check that edge cases mentioned are handled
Report each criterion:
Criterion: [exact criterion text]
Status: PASS / FAIL
Evidence: [specific file:line or behavior that confirms or denies — be concrete]
Also verify that the files listed in the task plan were actually created/modified:
Expected file: [path]
Status: EXISTS / MISSING
If no expected files are listed in the task plan, write a single row in the File Verification table: | (none listed) | N/A | and note in the regression check: "File coverage could not be verified — no files listed in task plan."
Step 4: Regression check
Identify files adjacent to the task's changes (same package/module, files that import the changed files).
Briefly check their core behaviors are not broken by the changes.
Report:
Regression check: CLEAR / CONCERNS
[If concerns: describe specifically what may be affected]
Step 5: Determine overall result
PASS: All acceptance criteria are PASS AND no regression concerns.
FAIL: Any criterion is FAIL OR regression concerns exist.
Step 6: Append to QA-LOG.md
Target file: .planning/phases/<current-phase>/QA-LOG.md
CRITICAL: Never overwrite QA-LOG.md. If it already exists, use an Edit or insert-at-end operation that preserves all prior content. Only create the file (with the header) if it does not yet exist.
If QA-LOG.md already contains a prior entry for this task, append the new result as an additional entry below the existing one. Do not modify or remove prior entries.
If QA-LOG.md does not exist, create it with this header first:
# QA Log — <current-phase>
Generated by /sdlc-qa-task — append-only
---
Then append this block:
## [PASS/FAIL] Task: {task-name}
**Date:** {YYYY-MM-DD}
**Reviewer:** QA Agent (sdlc-qa-task)
### Acceptance Criteria
| Criterion | Status | Evidence |
|-----------|--------|----------|
| {criterion} | PASS/FAIL | {evidence} |
### File Verification
| Expected File | Status |
|--------------|--------|
| {path} | EXISTS/MISSING |
### Regression Check
{CLEAR or description of concerns}
### Overall: {PASS/FAIL}
---
Step 7: Report to user
Tell the user:
- Overall result: PASS or FAIL
- How many criteria were checked (e.g., "3/3 criteria passed")
- Any regression concerns
- Path to QA-LOG.md
If FAIL:
List each failing criterion and what specific change is needed to fix it.
Say: "Fix the failing criteria and re-run /sdlc-qa-task '[task-name]' to re-verify."
If PASS:
Say: "Task '[task-name]' QA passed. Result logged to [QA-LOG.md path]. Continue with the next task or run /sdlc-qa-task for another task."