- Nx 22.7 monorepo (pnpm 11.1, TypeScript 5.9, Node 24) - apps/api: NestJS 11 (CJS conforme CODING-RULES.md PGD-DB-004) - apps/web: React 19 + Vite 8 (ESM) - libs/shared/api-interface: Zod contract base - Docker Compose dev: Postgres 18, Valkey 8, MinIO, Mailpit - WDS artifacts: - design-artifacts/A-Product-Brief/ (5 docs canônicos + 16 dialogs) - design-artifacts/B-Trigger-Map/ (hub + 4 personas + feature impact) - Stack canon: STACK.md v2.2 + CODING-RULES.md v2.0 + brand.md - AGENTS.md + README.md como entrada para devs/agentes Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
3.7 KiB
name, description, nextStepFile, outputFile
| name | description | nextStepFile | outputFile |
|---|---|---|---|
| step-01-detect-mode | Determine system-level vs epic-level mode and validate prerequisites | {skill-root}/steps-c/step-02-load-context.md | {test_artifacts}/test-design-progress.md |
Step 1: Detect Mode & Prerequisites
STEP GOAL
Determine whether to run System-Level or Epic-Level test design, and confirm required inputs are available.
MANDATORY EXECUTION RULES
Universal Rules
- 📖 Read this entire step file before taking any action
- ✅ Speak in
{communication_language} - 🚫 Do not load the next step until this step is complete
Role Reinforcement
- ✅ You are the Master Test Architect
- ✅ You prioritize risk-based, evidence-backed decisions
EXECUTION PROTOCOLS:
- 🎯 Follow the MANDATORY SEQUENCE exactly
- 💾 Record outputs before proceeding
- 📖 Load the next step only when instructed
CONTEXT BOUNDARIES:
- Available context: config, loaded artifacts, and knowledge fragments
- Focus: this step's goal only
- Limits: do not execute future steps
- Dependencies: prior steps' outputs (if any)
MANDATORY SEQUENCE
CRITICAL: Follow this sequence exactly. Do not skip, reorder, or improvise.
1. Mode Detection (Priority Order)
A) User Intent (Highest Priority)
Use explicit intent if the user already indicates scope:
- PRD + ADR (no epic/stories) → System-Level Mode
- Epic + Stories (no PRD/ADR) → Epic-Level Mode
- Both PRD/ADR + Epic/Stories → Prefer System-Level Mode first
If intent is unclear, ask:
"Should I create (A) System-level test design (PRD + ADR → Architecture + QA docs), or (B) Epic-level test design (Epic → single test plan)?"
B) File-Based Detection (BMad-Integrated)
If user intent is unclear:
- If
{implementation_artifacts}/sprint-status.yamlexists → Epic-Level Mode - Otherwise → System-Level Mode
C) Ambiguous → Ask
If mode still unclear, ask the user to choose (A) or (B) and halt until they respond.
2. Prerequisite Check (Mode-Specific)
System-Level Mode Requires:
- PRD (functional + non-functional requirements)
- ADR or architecture decision records
- Architecture or tech-spec document
Epic-Level Mode Requires:
- Epic and/or story requirements with acceptance criteria
- Architecture context (if available)
HALT CONDITIONS
If required inputs are missing and the user cannot provide them:
- System-Level: "Please provide PRD + ADR/architecture docs to proceed."
- Epic-Level: "Please provide epic/story requirements or acceptance criteria to proceed."
3. Confirm Mode
State which mode you will use and why. Then proceed.
4. Save Progress
Save this step's accumulated work to {outputFile}.
-
If
{outputFile}does not exist (first save), create it with YAML frontmatter:--- workflowStatus: 'in-progress' totalSteps: 5 stepsCompleted: ['step-01-detect-mode'] lastStep: 'step-01-detect-mode' nextStep: '{nextStepFile}' lastSaved: '{date}' ---Then write this step's output below the frontmatter.
-
If
{outputFile}already exists, update:- Set
workflowStatus: 'in-progress' - Set
totalSteps: 5 - Add
'step-01-detect-mode'tostepsCompletedarray (only if not already present) - Set
lastStep: 'step-01-detect-mode' - Set
nextStep: '{nextStepFile}' - Set
lastSaved: '{date}' - Append this step's output to the appropriate section of the document.
- Set
Load next step: {nextStepFile}
🚨 SYSTEM SUCCESS/FAILURE METRICS:
✅ SUCCESS:
- Step completed in full with required outputs
❌ SYSTEM FAILURE:
- Skipped sequence steps or missing outputs Master Rule: Skipping steps is FORBIDDEN.