Skip to content
Back to skills

Traceability

ASecurity

WAY 14 — requirements traceability matrix for a user story (each acceptance criterion) or a test folder written from plain text (each R-NN requirement) → the tests covering it → their latest result → open bugs. Use when the user says "trace it", "traceability", "is #148 covered", "coverage of SHOP-148", "trace it <folder>".

  • 5 stars
  • 0 votes
  • 0 copies
  • 6 views
  • Added October 12, 2026
testing

Security analysis

A100/100

Scanned December 4, 2026

npx -y skills add GhassenAZZOUZ/claude-qa-agent --skill traceability --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Traceability?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Traceability
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ghassenazzouz-traceability/badge)](https://www.skillsdirectory.com/skills/ghassenazzouz-traceability)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: traceability
description: 'WAY 14 — requirements traceability matrix for a user story (each acceptance criterion) or a test folder written from plain text (each R-NN requirement) → the tests covering it → their latest result → open bugs. Use when the user says "trace it", "traceability", "is #148 covered", "coverage of SHOP-148", "trace it <folder>".'
---

# WAY 14 — Traceability Matrix

## Step 1: Gather inputs
One or more story refs, or test folders whose requirements are plain text (`trace it password-reset-2026-10-13`, the folder name under `qa-artifacts/test-cases/`). At least one is required.

## Phase 1: Build the matrix
For each story:
1. **Requirements** (IDs per `requirements-analysis` §3):
   - Story ref: `issue.get`, then parse the Acceptance Criteria table (`AC-01 … AC-nn`, title, priority) from the `user-story-format` body. If the story has no ACs, use the `## Requirements` table (`R-NN`) of the test folders whose index has `**Source:** <ref>`. If there's neither, say so and suggest `enhance us <ref>` (WAY 6) first
   - Folder: the `## Requirements` table of its index `.md` (`**Source:** text`). If it has none, its tests predate R-NN: list them all as untraced and suggest `write it` to re-derive
   - A story that has ACs while some of its folders cite `R-NN`: trace against the ACs, and list those tests as untraced with "re-trace with `write it <ref>`"
2. **Tests:** Grep `qa-artifacts/test-cases/**` for `**Source:** <ref>` (or take the given folder). In those folders, read each `Test#<nn>.md` `**Covers:**` line and the `# Test#<nn> | AC-<NN>` / `R-<NN>` comments in the `.feature`
3. **Planned:** if a test plan has `**Source:** <ref>` (`qa-artifacts/test-plans/`, or the `test-plan` issue linked to the story), read its Planned tests rows per requirement. A planned test with no `Test#<nn>.feature` in the plan's test folder is **planned, not written**
4. **Latest result:** for each test, take the newest `runs/*/results.json` that contains its spec, and its status there (plus the run date)
5. **Bugs:** `issue.list` with label `bug` and the test folder name as search text (bug bodies cite the test path), plus bugs that reference the story ref. Keep the open ones

## Phase 2: Classify each AC

| Status | Meaning |
|---|---|
| 🟢 covered — passing | ≥1 test, all passing in their latest run |
| 🔴 covered — failing | ≥1 test failing, or an open bug |
| 🟡 covered — not run | tests exist, no run found |
| 🔵 planned — not written | only the plan has tests for it: run `write it Plan: <ref>` |
| ⚪ untested | no test mentions this AC |

Tests marked `**Covers:** untraced` are listed separately. They test something the story doesn't state, which is a hint the story is incomplete.

## Phase 3: Report
Save `./qa-artifacts/traceability/<ref-or-folder>-<YYYY-MM-DD>.md` (for a folder, the AC column holds `R-NN` and the header says `Requirements: plain text, IDs derived`):

```markdown
# Traceability — <ref> <story title>
**Coverage:** 5/7 ACs tested · 4 passing · 1 failing · 2 untested

| AC | Title | Priority | Tests | Latest result | Open bugs | Status |
|---|---|---|---|---|---|---|
| AC-01 | Apply a valid code | must | Test#01, Test#02 | ✅ ✅ (2026-10-09) | — | 🟢 |
| AC-04 | Expired code rejected | must | — | — | — | ⚪ |

**Untraced tests:** Test#07 (checks currency rounding: not in any AC)

---
🤖 _Generated by QA QualiGate — review before acting on this._
```

Print the summary. Ask the user before posting it as a comment on the story (a folder has no story to post on). For untested `must` requirements, offer `write it <ref>` (WAY 4).

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in testing →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.