bmad-method-test-architecture-enterprise 3.6.0 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/README.md +10 -3
  3. package/cli/lib/automate-prompt.js +3 -7
  4. package/cli/lib/framework-setup.js +1 -2
  5. package/cli/lib/parse-report.js +1 -1
  6. package/cli/lib/resolve-tea-config.js +76 -10
  7. package/cli/lib/trace-command.js +12 -4
  8. package/cli/migrate-customizations.js +678 -71
  9. package/cli/teach.js +0 -1
  10. package/cli/test-review.js +1 -1
  11. package/package.json +3 -2
  12. package/skills/bmad-tea/SKILL.md +2 -2
  13. package/skills/bmad-tea-automate/SKILL.md +12 -11
  14. package/skills/bmad-tea-automate/customize.toml +12 -0
  15. package/skills/bmad-tea-automate/red/atdd-checklist-template.md +4 -4
  16. package/skills/bmad-tea-automate/red/checklist.md +1 -0
  17. package/skills/bmad-tea-automate/red/instructions.md +1 -1
  18. package/skills/bmad-tea-automate/red/steps-c/step-04a-subagent-api-failing.md +5 -0
  19. package/skills/bmad-tea-automate/red/steps-c/step-04b-subagent-e2e-failing.md +4 -0
  20. package/skills/bmad-tea-automate/red/steps-c/step-04c-aggregate.md +3 -2
  21. package/skills/bmad-tea-automate/red/steps-c/step-05-validate-and-complete.md +5 -4
  22. package/skills/bmad-tea-automate/red/steps-e/step-02-apply-edit.md +4 -4
  23. package/skills/bmad-tea-automate/red/steps-v/step-01-validate.md +4 -4
  24. package/skills/bmad-tea-automate/red/workflow.yaml +0 -1
  25. package/skills/bmad-tea-automate/resources/test-generation-routing.md +4 -7
  26. package/skills/bmad-tea-automate/steps-c/step-04-validate-and-summarize.md +4 -4
  27. package/skills/bmad-tea-automate/steps-e/step-02-apply-edit.md +4 -4
  28. package/skills/bmad-tea-automate/steps-v/step-01-validate.md +4 -4
  29. package/skills/bmad-tea-automate/workflow.yaml +0 -1
  30. package/skills/bmad-tea-evaluate/SKILL.md +1 -1
  31. package/skills/bmad-tea-framework/SKILL.md +3 -3
  32. package/skills/bmad-tea-framework/customize.toml +11 -2
  33. package/skills/bmad-tea-framework/resources/hooks/tea-enforce.cjs +55 -24
  34. package/skills/bmad-tea-framework/resources/setup-routing.md +6 -6
  35. package/skills/bmad-tea-framework/steps-c/step-04-docs-and-scripts.md +16 -12
  36. package/skills/bmad-tea-framework/workflow.yaml +0 -1
  37. package/skills/bmad-tea-nfr/SKILL.md +2 -2
  38. package/skills/bmad-tea-nfr/workflow.yaml +0 -1
  39. package/skills/bmad-tea-teach-me-testing/SKILL.md +2 -2
  40. package/skills/bmad-tea-test-design/SKILL.md +2 -2
  41. package/skills/bmad-tea-test-design/workflow.yaml +0 -1
  42. package/skills/bmad-tea-test-review/SKILL.md +2 -2
  43. package/skills/bmad-tea-test-review/workflow.yaml +0 -1
  44. package/skills/bmad-tea-trace/SKILL.md +2 -2
  45. package/skills/bmad-tea-trace/steps-c/step-04-analyze-gaps.md +1 -0
  46. package/skills/bmad-tea-trace/steps-c/step-05-gate-decision.md +29 -12
  47. package/skills/bmad-tea-trace/workflow.yaml +0 -1
  48. package/skills/bmod-tea/bmod.toml +2 -2
  49. package/skills/bmod-tea/help/help.md +10 -9
  50. package/skills/bmod-tea/knowledge/maestro-flows.md +1 -1
  51. package/skills/bmod-tea/migration-1.toml +7 -7
  52. package/skills/bmod-tea/migration-3.toml +50 -0
  53. package/skills/bmod-tea/retired.toml +13 -0
  54. package/skills/bmad-tea-automate/red/customize.toml +0 -38
  55. package/skills/bmad-tea-framework/ci/customize.toml +0 -10
package/cli/teach.js CHANGED
@@ -144,7 +144,6 @@ function run(argv = process.argv) {
144
144
  ...consumedInputs,
145
145
  ...[
146
146
  '_bmad/config.toml',
147
- '_bmad/config.user.toml',
148
147
  '_bmad/custom/config.toml',
149
148
  '_bmad/custom/config.user.toml',
150
149
  'package.json',
@@ -1525,7 +1525,7 @@ async function runReview(session) {
1525
1525
  copyReportArtifact(agentOutputPath, outputPath, copiedReportTemporaryPath);
1526
1526
  }
1527
1527
 
1528
- let rawReport = fs.readFileSync(agentOutputPath, 'utf8');
1528
+ let rawReport = fs.readFileSync(agentOutputPath, 'utf8').replace(/^\uFEFF/, '');
1529
1529
  const parseAgentReport = (text) => {
1530
1530
  try {
1531
1531
  return parseReport(text, {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "bmad-method-test-architecture-enterprise",
4
- "version": "3.6.0",
4
+ "version": "4.0.0",
5
5
  "description": "Master Test Architect for quality strategy, test automation, and release gates",
6
6
  "keywords": [
7
7
  "bmad",
@@ -95,7 +95,7 @@
95
95
  "release:major": "gh workflow run publish.yaml -f bump=major",
96
96
  "release:minor": "gh workflow run publish.yaml -f bump=minor",
97
97
  "release:patch": "gh workflow run publish.yaml -f bump=patch",
98
- "test": "npm run test:conflict-markers && npm run test:schemas && npm run test:install && npm run test:evaluate-guidance && npm run test:evaluate-authoring && npm run test:evaluate-gap-loop && npm run test:evaluate-dogfood && npm run test:evaluate-check && npm run test:evaluate-discovery && npm run test:evaluate-generator && npm run test:evaluate-candidate-review && npm run test:evaluate-compare && npm run test:evaluate-before-state && npm run test:evaluate-ci-gates && npm run test:evaluate-ci-tiers && npm run test:evaluate-ci-repositories:tagged-release-pr && npm run test:evaluate-ci-repositories:tagged-release-merge && npm run test:evaluate-ci-repositories:tagged-release-release && npm run test:evaluate-ci-repositories:nightly-deploy-pr && npm run test:evaluate-ci-repositories:nightly-deploy-merge && npm run test:evaluate-ci-repositories:nightly-deploy-scheduled && npm run test:evaluate-ci-repositories:nightly-deploy-release && npm run test:evaluate-ci-render && npm run test:evaluate-pr-mcp && npm run test:evaluate-pr-api && npm run test:evaluate-pr-suite && npm run test:evaluate-pr-workflow && npm run test:evaluate-pr-tool-use && npm run test:evaluate-pr-promptfoo && npm run test:evaluate-pr-ai-feature && npm run test:evaluate-pr-test-review && npm run test:evaluate-pr-gap-loop && npm run test:evaluate-pr-learn && npm run test:evaluate-pr-tutorial && npm run test:evaluate-partitions && npm run test:evaluate-partition-plans-views-and-check && npm run test:evaluate-partition-plans-preflight-and-run && npm run test:evaluate-partition-plans-score && npm run test:evaluate-partition-plans-attempts-seal-and-mappings && npm run test:evaluate-partition-plans-attempts-records && npm run test:evaluate-partition-plans-attempts-gameability && npm run test:evaluate-interpret && npm run test:evaluate-calibration && npm run test:evaluate-boundaries && npm run test:evaluate-preflight && npm run test:evaluate-isolation-conformance && npm run test:evaluate-mutation:qualification-basics && npm run test:evaluate-mutation:qualification-guards && npm run test:evaluate-mutation:recovery && npm run test:evaluate-mutation:journals && npm run test:evaluate-run && npm run test:evaluate-progress && npm run test:evaluate-aggregate && npm run test:evaluate-confinement && npm run test:evaluate-confinement-audit && npm run test:evaluate-confinement-history && npm run test:evaluate-confinement-git-state && npm run test:evaluate-confinement-network && npm run test:evaluate-held-inputs && npm run test:evaluate-arms-historical && npm run test:evaluate-arms-deployments && npm run test:evaluate-evaluators && npm run test:evaluate-evaluators-agent-version && npm run test:evaluate-agents && npm run test:evaluate-agents-importers && npm run test:evaluate-agents-sealed-brief && npm run test:evaluate-held-attempts && npm run test:evaluate-private && npm run test:evaluate-records && npm run test:evaluate-mcp && npm run test:evaluate-api && npm run test:evaluate-workflow && npm run test:evaluate-tool-use && npm run test:evaluate-promptfoo && npm run test:evaluate-learned-framework && npm run test:docs-tutorial && npm run test:knowledge && npm run test:criteria-fragments && npm run test:doc-count-sources && npm run test:planning-doc-sources && npm run test:doc-counts && npm run test:doc-claim-sources && npm run test:doc-claims && npm run test:doc-invocation-entry && npm run test:doc-invocations && npm run test:doc-link-anchors && npm run test:docs-build-names && npm run test:doc-shell-blocks && npm run test:doc-ci-samples && npm run test:doc-playwright-examples && npm run test:docs-evaluate-sidebar && npm run test:docs-general-claims && npm run test:docs-gap-reader && npm run test:enforce-hook && npm run test:framework-scaffold && npm run test:isolation-primitives && npm run test:atdd-isolation && npm run test:atdd-net-guard && npm run test:atdd-scoring && npm run test:atdd-workflow-guidance && npm run test:generation-healing && npm run test:framework-scaffold-install-isolation && npm run test:transcript-harness && npm run test:suite-manifest && npm run test:teach-me-testing-scoring && npm run test:teach-cli && npm run test:eval-data && npm run test:eval-atdd-data && npm run test:eval-ci-data && npm run test:eval-framework-scaffold-data && npm run test:eval-nfr-data && npm run test:nfr-validate-corpus && npm run test:nfr-evidence-guidance && npm run test:nfr-cli && npm run test:eval-test-design-data && npm run test:eval-trace-data && npm run test:eval-routing-data && npm run test:eval-routing-boundaries && npm run test:eval-routing-evidence && npm run test:eval-transcript-data && npm run test:eval-teach-me-testing-data && npm run test:eval-schemas && npm run test:eval-diagnostics && npm run test:eval-replay && npm run test:eval-quality-corpus && npm run test:schema-versions && npm run test:contract-sources && npm run test:contracts && npm run test:contract-oracles && npm run test:probe-sources && npm run test:test-design-qualification && npm run test:test-review-qualification && npm run test:trace-qualification && npm run test:nfr-qualification && npm run test:ci-qualification && npm run test:probe-corpus && npm run test:compare-dominance && npm run test:compare-eval-runs && npm run test:configuration-experiment && npm run test:evaluate-experiments && npm run test:trial-set-scoring && npm run test:automate-cli && npm run test:automate-unit-runners && npm run test:automate-generation-evidence && npm run test:automate-eval-fixture && npm run test:eval-automate-data && npm run test:clock-port && npm run test:probe-conformance && npm run test:corpus-conformance && npm run test:file-system-conformance && npm run test:file-system-port && npm run test:probe-targets && npm run test:port-totality && npm run test:ci-coverage && npm run test:ci-coverage-filters && npm run test:install-actionlint && npm run test:workflows-lint && npm run test:artifact-retry && npm run test:install-linux-sandbox && npm run test:shards && npm run test:groups && npm run test:cli && npm run test:workflow-cli && npm run test:migrate-customizations && npm run test:framework-cli && npm run test:test-review-pr-scope && npm run test:test-review-report && npm run test:test-review-rubric && npm run test:bmad-output-gated && npm run test:release-metadata && npm run test:release-notes && npm run test:lockfile-age && npm run test:lockfile-age-cache && npm run test:licences && npm run test:supply-chain && npm run test:boundary && npm run test:direction && npm run test:lineage && npm run test:guard-publish && npm run test:layering-boundary-lineage && npm run test:changelog && npm run test:tea-workflow-descriptions && npm run test:docs-mermaid && npm run test:llms-headroom && npm run validate:schemas && npm run lint && npm run lint:md && npm run format:check",
98
+ "test": "npm run test:conflict-markers && npm run test:schemas && npm run test:install && npm run test:evaluate-guidance && npm run test:evaluate-authoring && npm run test:evaluate-gap-loop && npm run test:evaluate-dogfood && npm run test:evaluate-check && npm run test:evaluate-discovery && npm run test:evaluate-generator && npm run test:evaluate-candidate-review && npm run test:evaluate-compare && npm run test:evaluate-before-state && npm run test:evaluate-ci-gates && npm run test:evaluate-ci-tiers && npm run test:evaluate-ci-repositories:tagged-release-pr && npm run test:evaluate-ci-repositories:tagged-release-merge && npm run test:evaluate-ci-repositories:tagged-release-release && npm run test:evaluate-ci-repositories:nightly-deploy-pr && npm run test:evaluate-ci-repositories:nightly-deploy-merge && npm run test:evaluate-ci-repositories:nightly-deploy-scheduled && npm run test:evaluate-ci-repositories:nightly-deploy-release && npm run test:evaluate-ci-render && npm run test:evaluate-pr-mcp && npm run test:evaluate-pr-api && npm run test:evaluate-pr-suite && npm run test:evaluate-pr-workflow && npm run test:evaluate-pr-tool-use && npm run test:evaluate-pr-promptfoo && npm run test:evaluate-pr-ai-feature && npm run test:evaluate-pr-test-review && npm run test:evaluate-pr-gap-loop && npm run test:evaluate-pr-learn && npm run test:evaluate-pr-tutorial && npm run test:evaluate-partitions && npm run test:evaluate-partition-plans-views-and-check && npm run test:evaluate-partition-plans-preflight-and-run && npm run test:evaluate-partition-plans-score && npm run test:evaluate-partition-plans-attempts-seal-and-mappings && npm run test:evaluate-partition-plans-attempts-records && npm run test:evaluate-partition-plans-attempts-gameability && npm run test:evaluate-interpret && npm run test:evaluate-calibration && npm run test:evaluate-boundaries && npm run test:evaluate-preflight && npm run test:evaluate-isolation-conformance && npm run test:evaluate-mutation:qualification-basics && npm run test:evaluate-mutation:qualification-guards && npm run test:evaluate-mutation:recovery && npm run test:evaluate-mutation:journals && npm run test:evaluate-run && npm run test:evaluate-progress && npm run test:evaluate-aggregate && npm run test:evaluate-confinement && npm run test:evaluate-confinement-audit && npm run test:evaluate-confinement-history && npm run test:evaluate-confinement-git-state && npm run test:evaluate-confinement-network && npm run test:evaluate-held-inputs && npm run test:evaluate-arms-historical && npm run test:evaluate-arms-deployments && npm run test:evaluate-evaluators && npm run test:evaluate-evaluators-agent-version && npm run test:evaluate-agents && npm run test:evaluate-agents-importers && npm run test:evaluate-agents-sealed-brief && npm run test:evaluate-held-attempts && npm run test:evaluate-private && npm run test:evaluate-records && npm run test:evaluate-mcp && npm run test:evaluate-api && npm run test:evaluate-workflow && npm run test:evaluate-tool-use && npm run test:evaluate-promptfoo && npm run test:evaluate-learned-framework && npm run test:docs-tutorial && npm run test:knowledge && npm run test:criteria-fragments && npm run test:doc-count-sources && npm run test:planning-doc-sources && npm run test:doc-counts && npm run test:doc-claim-sources && npm run test:doc-claims && npm run test:doc-invocation-entry && npm run test:doc-invocations && npm run test:doc-link-anchors && npm run test:docs-build-names && npm run test:doc-shell-blocks && npm run test:doc-ci-samples && npm run test:doc-playwright-examples && npm run test:docs-evaluate-sidebar && npm run test:docs-general-claims && npm run test:docs-gap-reader && npm run test:enforce-hook && npm run test:framework-scaffold && npm run test:isolation-primitives && npm run test:atdd-isolation && npm run test:atdd-net-guard && npm run test:atdd-scoring && npm run test:atdd-workflow-guidance && npm run test:generation-healing && npm run test:framework-scaffold-install-isolation && npm run test:transcript-harness && npm run test:suite-manifest && npm run test:teach-me-testing-scoring && npm run test:teach-cli && npm run test:eval-data && npm run test:eval-atdd-data && npm run test:eval-ci-data && npm run test:eval-framework-scaffold-data && npm run test:eval-nfr-data && npm run test:nfr-validate-corpus && npm run test:nfr-evidence-guidance && npm run test:nfr-cli && npm run test:eval-test-design-data && npm run test:eval-trace-data && npm run test:eval-routing-data && npm run test:eval-routing-boundaries && npm run test:eval-routing-evidence && npm run test:eval-transcript-data && npm run test:eval-teach-me-testing-data && npm run test:eval-schemas && npm run test:eval-diagnostics && npm run test:eval-replay && npm run test:eval-quality-corpus && npm run test:schema-versions && npm run test:contract-sources && npm run test:contracts && npm run test:contract-oracles && npm run test:probe-sources && npm run test:test-design-qualification && npm run test:test-review-qualification && npm run test:trace-qualification && npm run test:nfr-qualification && npm run test:ci-qualification && npm run test:probe-corpus && npm run test:compare-dominance && npm run test:compare-eval-runs && npm run test:configuration-experiment && npm run test:evaluate-experiments && npm run test:trial-set-scoring && npm run test:automate-cli && npm run test:automate-unit-runners && npm run test:automate-generation-evidence && npm run test:automate-eval-fixture && npm run test:eval-automate-data && npm run test:clock-port && npm run test:probe-conformance && npm run test:corpus-conformance && npm run test:file-system-conformance && npm run test:file-system-port && npm run test:probe-targets && npm run test:port-totality && npm run test:ci-coverage && npm run test:ci-coverage-filters && npm run test:install-actionlint && npm run test:workflows-lint && npm run test:artifact-retry && npm run test:install-linux-sandbox && npm run test:shards && npm run test:groups && npm run test:cli && npm run test:workflow-cli && npm run test:migrate-customizations && npm run test:customization-surfaces && npm run test:framework-cli && npm run test:test-review-pr-scope && npm run test:test-review-report && npm run test:test-review-rubric && npm run test:bmad-output-gated && npm run test:release-metadata && npm run test:release-notes && npm run test:lockfile-age && npm run test:lockfile-age-cache && npm run test:licences && npm run test:supply-chain && npm run test:boundary && npm run test:direction && npm run test:lineage && npm run test:guard-publish && npm run test:layering-boundary-lineage && npm run test:changelog && npm run test:tea-workflow-descriptions && npm run test:docs-mermaid && npm run test:llms-headroom && npm run validate:schemas && npm run lint && npm run lint:md && npm run format:check",
99
99
  "test:artifact-retry": "node test/test-artifact-retry.js",
100
100
  "test:atdd-isolation": "node test/test-atdd-isolation.js",
101
101
  "test:atdd-net-guard": "node test/test-atdd-net-guard.js",
@@ -123,6 +123,7 @@
123
123
  "test:corpus-conformance": "node test/test-corpus-conformance.js",
124
124
  "test:coverage": "c8 npm test",
125
125
  "test:criteria-fragments": "node tools/validate-criteria-fragments.js",
126
+ "test:customization-surfaces": "node test/test-customization-surfaces.js",
126
127
  "test:direction": "eval-quality-gates dependency-direction",
127
128
  "test:doc-ci-samples": "node test/test-doc-ci-samples.js",
128
129
  "test:doc-claim-sources": "node test/test-doc-claim-sources.js",
@@ -19,7 +19,7 @@ You are Murat, the Master Test Architect and Quality Advisor. You lead risk-base
19
19
 
20
20
  ## On Activation
21
21
 
22
- Before resolving the agent menu, inspect `{project-root}/_bmad/custom/bmad-tea.toml` and `{project-root}/_bmad/custom/bmad-tea.user.toml` for `skill` values beginning `bmad-testarch-` or equal to `bmad-teach-me-testing`. If found, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@3 tea-migrate-customizations --project-root {project-root}`. A migration conflict requires the manual merge named by that command. Start a fresh chat after migration so the old menu cannot dispatch removed commands.
22
+ Before resolving the agent menu, inspect `{project-root}/_bmad/custom/bmad-tea.toml` and `{project-root}/_bmad/custom/bmad-tea.user.toml` for `skill` values beginning `bmad-testarch-` or equal to `bmad-teach-me-testing`. If found, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@4 tea-migrate-customizations --project-root {project-root}`. A migration conflict requires the manual merge named by that command. Start a fresh chat after migration so the old menu cannot dispatch removed commands.
23
23
 
24
24
  ### Step 1: Resolve the Agent Block
25
25
 
@@ -53,7 +53,7 @@ Run `uv run {project-root}/_bmad/scripts/resolve_config.py --project-root {proje
53
53
 
54
54
  Each `core` and `modules.tea` key is available as `{<key>}`, and as `config.<key>` in later steps. Replace `{project-root}` inside a value with the project root. Setup answers are strings: read `"true"` and `"false"` as booleans.
55
55
 
56
- If `{tea-knowledge}/tea-index.csv` does not exist, the TEA knowledge base is not installed. Tell the user, offer to install it with `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`, run that on a yes, and stop until it is there.
56
+ If `{tea-knowledge}/tea-index.csv` does not exist, the `bmod-tea` skill is not installed beside this one (`{skill-root}/../bmod-tea`). Tell the user to install `bmod-tea` in the same scope as this skill, and stop until it is there. For a skill in the project's skills folder run `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`; for a skill in the global skills folder add `-g`. Run the command on a yes. A headless run has no approval input: report the missing dependency and stop without running the installer. A `bmod-tea` installed in the other scope does not satisfy this skill.
57
57
 
58
58
  - Use `{user_name}` for greeting
59
59
  - Use `{communication_language}` for all communications
@@ -23,26 +23,27 @@ You will continue to operate with your given name, identity, and communication_s
23
23
 
24
24
  ## Route Before Activation
25
25
 
26
- Read `{skill-root}/resources/test-generation-routing.md` completely and resolve `test_mode`, `test_operation`, and `workflow-skill-root` before executing activation.
26
+ Read `{skill-root}/resources/test-generation-routing.md` completely and resolve `test_mode`, `test_operation`, and `workflow-key` before executing activation.
27
27
  Keep `{skill-root}` bound to this canonical directory throughout both modes.
28
- The router selects exactly one customization surface; activation below uses that surface only.
28
+ The router selects exactly one customization key (`workflow` for expand, `workflow.red` for red); activation below uses that key only.
29
29
 
30
30
  ## On Activation
31
31
 
32
- Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-automate.toml`, `bmad-testarch-automate.user.toml`, `bmad-testarch-atdd.toml`, and `bmad-testarch-atdd.user.toml`. If any exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@3 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
32
+ Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-automate.toml`, `bmad-testarch-automate.user.toml`, `bmad-testarch-atdd.toml`, `bmad-testarch-atdd.user.toml`, `bmad-tea-atdd.toml`, and `bmad-tea-atdd.user.toml`. Red settings live under `[workflow.red]` in `bmad-tea-automate.toml` and `.user.toml`; the atdd files are read nowhere. If any exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@4 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
33
33
 
34
34
  ### Step 1: Resolve the Workflow Block
35
35
 
36
- When `workflow_customization_manual = true`, use the already resolved red workflow block and skip this resolver command.
37
- Otherwise run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow`
36
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}`
38
37
 
39
- **If the script fails**, resolve the `workflow` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver:
38
+ The returned object is the `workflow` block for the rest of the run: `{workflow.activation_steps_prepend}`, `{workflow.persistent_facts}` and the other keys below read from it, whichever mode was selected.
40
39
 
41
- 1. `{workflow-skill-root}/customize.toml` (or `{skill-root}/red/customize.toml` for canonical-only red) — defaults
42
- 2. `{project-root}/_bmad/custom/{workflow-skill-name}.toml` — team overrides
43
- 3. `{project-root}/_bmad/custom/{workflow-skill-name}.user.toml` — personal overrides
40
+ **If the script fails**, resolve the block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver:
44
41
 
45
- Any missing file is skipped. Scalars override, tables deep-merge, arrays of tables keyed by `code` or `id` replace matching entries and append new entries, and all other arrays append.
42
+ 1. `{skill-root}/customize.toml` — defaults
43
+ 2. `{project-root}/_bmad/custom/bmad-tea-automate.toml` — team overrides
44
+ 3. `{project-root}/_bmad/custom/bmad-tea-automate.user.toml` — personal overrides
45
+
46
+ Then take the `workflow` table, or its `red` sub-table when `workflow-key` is `workflow.red`. Any missing file is skipped. Scalars override, tables deep-merge, arrays of tables keyed by `code` or `id` replace matching entries and append new entries, and all other arrays append.
46
47
 
47
48
  ### Step 2: Execute Prepend Steps
48
49
 
@@ -58,7 +59,7 @@ Run `uv run {project-root}/_bmad/scripts/resolve_config.py --project-root {proje
58
59
 
59
60
  Each `core` and `modules.tea` key is available as `{<key>}`, and as `config.<key>` in later steps. Replace `{project-root}` inside a value with the project root. Setup answers are strings: read `"true"` and `"false"` as booleans.
60
61
 
61
- If `{tea-knowledge}/tea-index.csv` does not exist, the TEA knowledge base is not installed. Tell the user, offer to install it with `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`, run that on a yes, and stop until it is there.
62
+ If `{tea-knowledge}/tea-index.csv` does not exist, the `bmod-tea` skill is not installed beside this one (`{skill-root}/../bmod-tea`). Tell the user to install `bmod-tea` in the same scope as this skill, and stop until it is there. For a skill in the project's skills folder run `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`; for a skill in the global skills folder add `-g`. Run the command on a yes. A headless run has no approval input: report the missing dependency and stop without running the installer. A `bmod-tea` installed in the other scope does not satisfy this skill.
62
63
 
63
64
  ### Step 5: Greet the User
64
65
 
@@ -36,3 +36,15 @@ persistent_facts = []
36
36
  # Override wins. Leave empty for no custom post-completion behavior.
37
37
 
38
38
  on_complete = ""
39
+
40
+ # --- Red mode ---
41
+ # Settings for red mode (acceptance tests written before the implementation).
42
+ # Same keys and merge rules as [workflow]; only red mode reads this table, and
43
+ # expand mode never does. Override it under [workflow.red] in
44
+ # _bmad/custom/bmad-tea-automate.toml or bmad-tea-automate.user.toml.
45
+
46
+ [workflow.red]
47
+ activation_steps_prepend = []
48
+ activation_steps_append = []
49
+ persistent_facts = []
50
+ on_complete = ""
@@ -275,7 +275,7 @@ test('should do something', async ({ {fixtureName} }) => {
275
275
  **DEV Agent Responsibilities:**
276
276
 
277
277
  1. **Pick one scaffolded test** from implementation checklist (start with highest priority)
278
- 2. **Remove `test.skip()`** for that test and confirm it fails first
278
+ 2. **Remove `.skip` and the adjacent comment with its temporary reason** for that test and confirm it fails first
279
279
  3. **Read the test** to understand expected behavior
280
280
  4. **Implement minimal code** to make that specific test pass
281
281
  5. **Run the test** to verify it now passes (green)
@@ -329,7 +329,7 @@ test('should do something', async ({ {fixtureName} }) => {
329
329
  2. **If the story file cannot be updated automatically**, share this checklist and generated tests with the dev workflow as a manual handoff
330
330
  3. **Review this checklist** with team in standup or planning
331
331
  4. **Begin implementation** using implementation checklist as guide
332
- 5. **Activate one scaffold at a time** by removing `test.skip()` for the current task, then confirm it fails before implementing
332
+ 5. **Activate one scaffold at a time** by removing `.skip` and the adjacent comment with its temporary reason for the current task, then confirm it fails before implementing
333
333
  6. **Work one activated test at a time** (red → green for each)
334
334
  7. **Share progress** in daily standup
335
335
  8. **When all activated tests pass**, refactor code for quality
@@ -395,8 +395,8 @@ See `tea-index.csv` for complete knowledge fragment mapping.
395
395
  **Questions or Issues?**
396
396
 
397
397
  - Ask in team standup
398
- - Tag @{tea_agent_username} in Slack/Discord
399
- - Refer to `./bmm/docs/tea-README.md` for workflow documentation
398
+ - Ask your team’s test owner for project-specific guidance
399
+ - Refer to the [Automate workflow guide](https://bmad-code-org.github.io/bmad-method-test-architecture-enterprise/how-to/workflows/run-automate/)
400
400
  - Consult `{tea-knowledge}` for testing best practices
401
401
 
402
402
  ---
@@ -202,6 +202,7 @@ Before starting this workflow, verify:
202
202
  ### Red-Phase Scaffolds Verified
203
203
 
204
204
  - [ ] All generated acceptance test scaffolds are marked with `test.skip()`
205
+ - [ ] Every skipped leaf has an adjacent comment explaining that its red scaffold awaits implementation; activation removes `.skip` and the temporary reason before confirming RED
205
206
  - [ ] No scaffold was emitted as an active passing test before implementation
206
207
  - [ ] Create verification activates only generated leaf skips in a disposable copy; permanent scaffolds and all other skips remain unchanged
207
208
  - [ ] Implementation activation guidance is documented: remove the current task's leaf `test.skip()` when development begins, then confirm RED before implementing
@@ -26,7 +26,7 @@ This workflow uses **step-file architecture**:
26
26
 
27
27
  This instruction file owns red mode after canonical activation.
28
28
  Set `test_mode = red` when a direct runner loads this file without the shared router; keep `{skill-root}` canonical.
29
- Resolve red customization by merging `{skill-root}/red/customize.toml` with `_bmad/custom/bmad-tea-atdd.toml` and `.user.toml` manually and retain its workflow block.
29
+ Resolve red customization with `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key workflow.red` (set `workflow-key = workflow.red`) and retain its block.
30
30
  Entry activation and operation routing remain in `{skill-root}/SKILL.md`.
31
31
 
32
32
  ### 1. Configuration Loading
@@ -32,6 +32,7 @@ This is an **isolated subagent** running in parallel with E2E red-phase test gen
32
32
  - 📖 Read this entire subagent file before acting
33
33
  - ✅ Generate red-phase API test scaffolds ONLY
34
34
  - ✅ Tests MUST be emitted with `test.skip()` until the developer activates them
35
+ - ✅ Put an adjacent comment immediately above every skipped leaf explaining that the red scaffold awaits implementation. On activation, remove `.skip` and that temporary reason, then confirm RED before coding. Unexplained skips still produce C1 warnings.
35
36
  - ✅ Register each Playwright scaffold with a direct `test.skip` call and a literal criterion title. Literal `test.describe` suites may contain those calls. Avoid loops, `test.each()`, helper registrations, computed titles, and template titles; the CLI verifies each generated leaf against runner evidence.
36
37
  - ✅ Output structured JSON to temp file
37
38
  - ✅ Follow knowledge fragment patterns
@@ -73,6 +74,7 @@ import { test, expect } from '../support/merged-fixtures';
73
74
  import { registrationPayload } from '../support/factories';
74
75
 
75
76
  test.describe('[Story Name] API Tests (ATDD)', () => {
77
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
76
78
  test.skip('[P0] AC-1 should register new user successfully', async ({ apiRequest }) => {
77
79
  // THIS TEST WILL FAIL - Endpoint not implemented yet
78
80
  const { status, body } = await apiRequest<RegisteredUser>({
@@ -89,6 +91,7 @@ test.describe('[Story Name] API Tests (ATDD)', () => {
89
91
  });
90
92
  });
91
93
 
94
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
92
95
  test.skip('[P1] AC-2 should return 400 if email exists', async ({ apiRequest }) => {
93
96
  // THIS TEST WILL FAIL - Endpoint not implemented yet
94
97
  const { status, body } = await apiRequest({
@@ -111,6 +114,7 @@ test.describe('[Story Name] API Tests (ATDD)', () => {
111
114
  import { test, expect } from '@playwright/test';
112
115
 
113
116
  test.describe('[Story Name] API Tests (ATDD)', () => {
117
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
114
118
  test.skip('[P0] AC-1 should register new user successfully', async ({ request }) => {
115
119
  const response = await request.post('/api/users/register', {
116
120
  data: { email: 'newuser@example.com', password: 'SecurePass123!' },
@@ -191,6 +195,7 @@ When generating Pact consumer contract tests in the ATDD red phase, provider scr
191
195
  * - Status: 201 for success, 400 for duplicate email, 422 for validation error
192
196
  * - Response: { id: number, email: string, createdAt: string }
193
197
  */
198
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
194
199
  test.skip('[P0] AC-1 should generate consumer contract for user registration', async () => {
195
200
  await provider
196
201
  .given('no users exist')
@@ -29,6 +29,7 @@ This is an **isolated subagent** running in parallel with API red-phase test gen
29
29
  - 📖 Read this entire subagent file before acting
30
30
  - ✅ Generate red-phase E2E test scaffolds ONLY
31
31
  - ✅ Tests MUST be emitted with `test.skip()` until the developer activates them
32
+ - ✅ Put an adjacent comment immediately above every skipped leaf explaining that the red scaffold awaits implementation. On activation, remove `.skip` and that temporary reason, then confirm RED before coding. Unexplained skips still produce C1 warnings.
32
33
  - ✅ Register each Playwright scaffold with a direct `test.skip` call and a literal criterion title. Literal `test.describe` suites may contain those calls. Avoid loops, `test.each()`, helper registrations, computed titles, and template titles; the CLI verifies each generated leaf against runner evidence.
33
34
  - ✅ Output structured JSON to temp file
34
35
  - ✅ Follow knowledge fragment patterns
@@ -102,6 +103,7 @@ For each user journey, create test file in `tests/e2e/[feature].spec.ts`:
102
103
  import { test, expect } from '../support/merged-fixtures';
103
104
 
104
105
  test.describe('[Story Name] E2E User Journey (ATDD)', () => {
106
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
105
107
  test.skip('[P0] AC-1 should complete user registration successfully', async ({ page, interceptNetworkCall }) => {
106
108
  // The outer assertion is the first potentially failing operation. It owns
107
109
  // every navigation, interaction, network, and outcome failure in this AC.
@@ -122,6 +124,7 @@ test.describe('[Story Name] E2E User Journey (ATDD)', () => {
122
124
  });
123
125
 
124
126
  // Stubs a 409 on purpose, so it opts out of network monitoring.
127
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
125
128
  test.skip(
126
129
  '[P1] AC-2 should show error if email exists',
127
130
  { annotation: [{ type: 'skipNetworkMonitoring' }] },
@@ -155,6 +158,7 @@ Note the selectors: `getByLabel` and `getByRole`, never `[name="email"]` or `but
155
158
  import { test, expect } from '@playwright/test';
156
159
 
157
160
  test.describe('[Story Name] E2E User Journey (ATDD)', () => {
161
+ // Red scaffold: awaiting implementation. Activate this criterion and confirm RED before coding.
158
162
  test.skip('[P0] AC-1 should complete user registration successfully', async ({ page }) => {
159
163
  await expect(
160
164
  (async () => {
@@ -19,6 +19,7 @@ Read outputs from parallel subagents (API + E2E red-phase test generation), aggr
19
19
  - ✅ Speak in `{communication_language}`
20
20
  - ✅ Read subagent outputs from temp files
21
21
  - ✅ Verify all tests are marked with test.skip() (TDD red phase)
22
+ - ✅ Verify every skipped leaf has an adjacent comment explaining that its red scaffold awaits implementation. Keep that reason until activation, then remove `.skip` and the temporary reason together.
22
23
  - ✅ Generate shared fixtures based on fixture needs
23
24
  - ✅ Write all generated test files to disk
24
25
  - ❌ Do NOT remove test.skip() (that's done after feature implementation)
@@ -254,7 +255,7 @@ Note: More complete fixtures will be needed when moving to green phase.
254
255
 
255
256
  During implementation of each task:
256
257
 
257
- 1. Remove `test.skip()` from the current test file or scenario
258
+ 1. Remove `.skip` and the adjacent comment with its temporary reason from the current scenario
258
259
  2. Run tests: `npm test`
259
260
  3. Verify the activated test fails first, then passes after implementation (green phase)
260
261
  4. If any activated tests still fail unexpectedly:
@@ -381,7 +382,7 @@ Display to user:
381
382
  📝 Next Steps:
382
383
  1. Link ATDD artifacts into the story file if available
383
384
  2. Implement the feature
384
- 3. Remove test.skip() from the tests for the current task
385
+ 3. Remove `.skip` and the adjacent comment with its temporary reason from the tests for the current task
385
386
  4. Run activated tests → verify they FAIL before implementation, then PASS after implementation
386
387
  5. Commit passing tests
387
388
 
@@ -53,6 +53,7 @@ Use `{skill-root}/red/checklist.md` to validate:
53
53
  - Test files created correctly
54
54
  - Checklist matches acceptance criteria
55
55
  - Tests are generated as red-phase scaffolds and marked with `test.skip()`
56
+ - Every skipped leaf has an adjacent comment explaining that its red scaffold awaits implementation; activation removes `.skip` and the temporary reason before confirming RED
56
57
  - Preflight preserved supplied criterion ids and assigned stable, collision-free ids to unnamed criteria
57
58
  - Every executable leaf title carries exactly one id from the persisted criterion registry
58
59
  - Every declared acceptance criterion has exactly one red-phase leaf scaffold
@@ -144,12 +145,12 @@ Preserve or include the loop's resolved YAML frontmatter keys `test_mode`, `test
144
145
 
145
146
  ## On Complete
146
147
 
147
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
148
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
148
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
149
+ If it was not retained, resolve it from the selected key:
149
150
 
150
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
151
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
151
152
 
152
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
153
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
153
154
 
154
155
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
155
156
  Execute its non-empty value as the final terminal instruction.
@@ -63,12 +63,12 @@ Summarize the edits applied.
63
63
 
64
64
  ## On Complete
65
65
 
66
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
67
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
66
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
67
+ If it was not retained, resolve it from the selected key:
68
68
 
69
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
69
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
70
70
 
71
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
71
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
72
72
 
73
73
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
74
74
  Execute its non-empty value as the final terminal instruction.
@@ -90,12 +90,12 @@ Replace the `IN_PROGRESS` body in this run's reserved `{outputFile}` with the fi
90
90
 
91
91
  ## On Complete
92
92
 
93
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
94
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
93
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
94
+ If it was not retained, resolve it from the selected key:
95
95
 
96
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
96
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
97
97
 
98
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
98
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
99
99
 
100
100
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
101
101
  Execute its non-empty value as the final terminal instruction.
@@ -7,7 +7,6 @@ description: 'Generate red-phase acceptance test scaffolds using TDD cycle. Use
7
7
  date: system-generated
8
8
 
9
9
  # Workflow components
10
- installed_path: "red"
11
10
  instructions: "red/instructions.md"
12
11
  validation: "red/checklist.md"
13
12
  template: "red/atdd-checklist-template.md"
@@ -43,13 +43,10 @@ Do not restart Create or execute a completed generation step on an explicit Resu
43
43
 
44
44
  ## 2. Choose Exactly One Customization Surface
45
45
 
46
- For red set `workflow-skill-root = {skill-root}/red` and `workflow-skill-name = bmad-tea-atdd` to select the red customization namespace.
47
- For expand set `workflow-skill-root = {skill-root}` and `workflow-skill-name = bmad-tea-automate`.
48
- Resolve `{skill-root}/red/customize.toml` plus `_bmad/custom/bmad-tea-atdd.toml` and `.user.toml` manually with the activation merge rules; the resolver's directory-name inference cannot resolve this customization namespace from `red/`.
49
- Record `workflow_customization_manual = true` and retain the resolved workflow block for its terminal hook.
50
- Keep the resolver's workflow namespace and structural merge rules intact.
51
- Resolve only the selected surface's defaults, team file and user file.
52
- Red uses `_bmad/custom/bmad-tea-atdd.toml` and `.user.toml`; expand uses `_bmad/custom/bmad-tea-automate.toml` and `.user.toml`.
46
+ Both modes resolve from this skill's own `customize.toml` and `_bmad/custom/bmad-tea-automate.toml` and `.user.toml`.
47
+ For red set `workflow-key = workflow.red`. For expand set `workflow-key = workflow`.
48
+ `workflow.red` holds the red settings (`activation_steps_prepend`, `activation_steps_append`, `persistent_facts`, `on_complete`); expand never reads it and red never reads the top-level keys.
49
+ Resolve only the selected key, with `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}`, and retain the returned block for its terminal hook.
53
50
 
54
51
  Run selected prepend hooks, load selected persistent facts, load config, greet, then run selected append hooks in that order.
55
52
  The selected mode's `workflow.on_complete` executes at its original terminal after outputs are saved, including Validate and Edit.
@@ -132,12 +132,12 @@ Preserve or include the loop's resolved YAML frontmatter keys `test_mode`, `test
132
132
 
133
133
  ## On Complete
134
134
 
135
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
136
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
135
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
136
+ If it was not retained, resolve it from the selected key:
137
137
 
138
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
138
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
139
139
 
140
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
140
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
141
141
 
142
142
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
143
143
  Execute its non-empty value as the final terminal instruction.
@@ -63,12 +63,12 @@ Summarize the edits applied.
63
63
 
64
64
  ## On Complete
65
65
 
66
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
67
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
66
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
67
+ If it was not retained, resolve it from the selected key:
68
68
 
69
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
69
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
70
70
 
71
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
71
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
72
72
 
73
73
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
74
74
  Execute its non-empty value as the final terminal instruction.
@@ -89,12 +89,12 @@ Replace the `IN_PROGRESS` body in this run's reserved `{outputFile}` with the fi
89
89
 
90
90
  ## On Complete
91
91
 
92
- When `workflow_customization_manual = true`, execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally.
93
- Otherwise resolve the same selected customization surface below; never run the other mode's hook.
92
+ Execute the non-empty `workflow.on_complete` retained from selected-mode activation as the final terminal instruction, then exit normally; never run the other mode's hook.
93
+ If it was not retained, resolve it from the selected key:
94
94
 
95
- Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {workflow-skill-root} --project-root {project-root} --key workflow.on_complete`
95
+ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --project-root {project-root} --key {workflow-key}.on_complete`
96
96
 
97
- If the resolver succeeds and returns a non-empty `workflow.on_complete`, execute that value as the final terminal instruction before exiting.
97
+ If the resolver succeeds and returns a non-empty value for `{workflow-key}.on_complete`, execute that value as the final terminal instruction before exiting.
98
98
 
99
99
  If the resolver fails or returns no output, use the selected `workflow.on_complete` block already resolved during activation (or resolve the selected defaults/team/user files with the same structural merge rules).
100
100
  Execute its non-empty value as the final terminal instruction.
@@ -7,7 +7,6 @@ description: 'Generate tests in red or expand mode and run-and-heal new tests. U
7
7
  date: system-generated
8
8
 
9
9
  # Workflow components
10
- installed_path: "."
11
10
  instructions: "./instructions.md"
12
11
  validation: "./checklist.md"
13
12
  template: false
@@ -34,7 +34,7 @@ An explicit native compare/accept request keeps that command's authority, includ
34
34
 
35
35
  ## On Activation
36
36
 
37
- Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-evaluate.toml` and `bmad-testarch-evaluate.user.toml`. If either exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@3 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
37
+ Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-evaluate.toml` and `bmad-testarch-evaluate.user.toml`. If either exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@4 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
38
38
 
39
39
  ### Step 1: Resolve the Workflow Block
40
40
 
@@ -26,7 +26,7 @@ Before activation hooks or project writes, load `{skill-root}/resources/setup-ro
26
26
 
27
27
  ## On Activation
28
28
 
29
- Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-framework.toml`, `bmad-testarch-framework.user.toml`, `bmad-testarch-ci.toml`, and `bmad-testarch-ci.user.toml`. If any exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@3 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
29
+ Before resolving customizations or running hooks, inspect `{project-root}/_bmad/custom/` for `bmad-testarch-framework.toml`, `bmad-testarch-framework.user.toml`, `bmad-testarch-ci.toml`, `bmad-testarch-ci.user.toml`, `bmad-tea-ci.toml`, and `bmad-tea-ci.user.toml`. CI settings live under `[workflow.ci]` in `bmad-tea-framework.toml` and `.user.toml`; the ci files are read nowhere. Also stop when `[workflow]` of `bmad-tea-framework.toml` or `.user.toml` holds `ci_platform` directly, because only `[workflow.ci]` is read. If any exists, stop and tell the user to run `npx --package=bmad-method-test-architecture-enterprise@4 tea-migrate-customizations --project-root {project-root}`. Resolve any reported manual merge, then start a fresh chat. Do not continue with default settings while legacy overrides remain.
30
30
 
31
31
  ### Step 1: Resolve the Workflow Block
32
32
 
@@ -40,7 +40,7 @@ Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skil
40
40
 
41
41
  Any missing file is skipped. Scalars override, tables deep-merge, arrays of tables keyed by `code` or `id` replace matching entries and append new entries, and all other arrays append.
42
42
 
43
- When scope includes CI, resolve `ci_workflow` through `resources/setup-routing.md` section 2 before any CI hook, greeting, contract freeze or worker launch. Retain canonical `workflow` separately for explicit platform precedence. This resolution reads settings only; the activation stages below execute the applicable hooks and facts.
43
+ When scope includes CI, resolve `ci_workflow` through `resources/setup-routing.md` section 2 before any CI hook, greeting, contract freeze or worker launch. Retain canonical `workflow` separately. This resolution reads settings only; the activation stages below execute the applicable hooks and facts.
44
44
 
45
45
  ### Step 2: Execute Prepend Steps
46
46
 
@@ -56,7 +56,7 @@ Run `uv run {project-root}/_bmad/scripts/resolve_config.py --project-root {proje
56
56
 
57
57
  Each `core` and `modules.tea` key is available as `{<key>}`, and as `config.<key>` in later steps. Replace `{project-root}` inside a value with the project root. Setup answers are strings: read `"true"` and `"false"` as booleans.
58
58
 
59
- If `{tea-knowledge}/tea-index.csv` does not exist, the TEA knowledge base is not installed. Tell the user, offer to install it with `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`, run that on a yes, and stop until it is there.
59
+ If `{tea-knowledge}/tea-index.csv` does not exist, the `bmod-tea` skill is not installed beside this one (`{skill-root}/../bmod-tea`). Tell the user to install `bmod-tea` in the same scope as this skill, and stop until it is there. For a skill in the project's skills folder run `npx skills add bmad-code-org/bmad-method-test-architecture-enterprise --skill bmod-tea`; for a skill in the global skills folder add `-g`. Run the command on a yes. A headless run has no approval input: report the missing dependency and stop without running the installer. A `bmod-tea` installed in the other scope does not satisfy this skill.
60
60
 
61
61
  ### Step 5: Greet the User
62
62
 
@@ -37,6 +37,15 @@ persistent_facts = []
37
37
 
38
38
  on_complete = ""
39
39
 
40
- # Explicit canonical team/user override wins; otherwise CI alias ci_platform applies.
41
- # The default auto value does not mask a migrated bmad-tea-ci override.
40
+ # --- CI scope ---
41
+ # Settings for the CI phase (the pipeline written after the test framework).
42
+ # Same keys and merge rules as [workflow], plus ci_platform. Only CI scope
43
+ # reads this table. Override it under [workflow.ci] in
44
+ # _bmad/custom/bmad-tea-framework.toml or bmad-tea-framework.user.toml.
45
+
46
+ [workflow.ci]
47
+ activation_steps_prepend = []
48
+ activation_steps_append = []
49
+ persistent_facts = []
50
+ on_complete = ""
42
51
  ci_platform = "auto"