prd-test-writer

Generates story-driven PRDs and executable test cases with paired review HTML documents.

752|107|Updated Jan 19, 2026
One-click install
npx skills add https://github.com/yunshu0909/yunshu_skillshub --skill prd-test-writer
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prd-test-writer
Source: https://github.com/yunshu0909/yunshu_skillshub/tree/main/prd-test-writer
Command: npx skills add https://github.com/yunshu0909/yunshu_skillshub --skill prd-test-writer

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) and assets (resource) components.

What problem does it solve?

Writing a PRD and its test cases separately often produces misaligned documents: requirements that cannot be tested, test cases that invent fields not present in the code, and review HTML that silently drops content. This Skill co-produces a story-driven PRD and atomic, code-grounded test cases as one workflow, keeping both documents strictly consistent.

Core Features & Use Cases

  • Dual-document generation: Produces four artifacts per requirement — a PRD markdown and a test-case markdown (fact sources for AI) plus two template-based review HTML files for humans, verified 1:1 against the markdown via a scripted check.
  • Code-grounded test cases: Every assertion cites a file:line code reference, each case is a single atomic verification point with 13 fields, and task-type cases specify exact per-round prompts and expected results.
  • Structured collaboration flow: A six-phase loop (requirement confirmation, autonomous code reading, PRD story discussion, test case drafting, adversarial review by independent sub-agents, freeze and registry) with single-point user confirmation at each step.
  • Use Case: After a feature task is scoped, ask the agent to write the PRD and test cases; it reads the codebase first, drafts user stories with ASCII wireframes and Mermaid diagrams, then produces executable test cases with evidence types and failure classification.

Quick Start

Ask the agent to write the PRD and executable test cases for your already-scoped task, and confirm each stage as it walks through the six-phase workflow.

Frequently Asked Questions about prd-test-writer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write a PRD and test cases that stay consistent?

Use this Skill's dual-document workflow: it produces the PRD and test cases together in one staged process, with every test assertion traced to a code file and line. A scripted 1:1 check then verifies the review HTML matches the markdown sources exactly.

How to write executable test cases for AI agents?

Each case must be a single atomic verification point with 13 fields, including exact command literals, verbatim prompts, per-step expected results, and a code reference. Task-type cases must specify the task name, round count, and what is sent and expected in every round.

When should I not use this PRD and test case workflow?

Skip it when the requirement is still vague or not broken into tasks, when UI interaction has not been explored yet, when the change is a small modification to an existing shipped feature, or when you need code written or tests actually executed rather than documents.

Does the skill run the tests it writes?

No. It only produces documentation: the PRD, the test case document, and two review HTML files. Implementation and test execution are explicitly out of scope and handled by other steps in the delivery chain.

Why do test cases need code references for every assertion?

Requiring a file:line citation for each assertion prevents invented fields and false passing results. If an asserted field cannot be found in the codebase via grep, it is treated as fabricated and must be removed from the case.