agentvibes 3.0.0 → 3.2.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 (350) hide show
  1. package/.bmad/_cfg/agent-manifest.csv +9 -9
  2. package/.bmad/_cfg/agent-voice-map.csv +11 -11
  3. package/.bmad/_cfg/agents/bmm-quick-flow-solo-dev.customize.yaml +42 -0
  4. package/.bmad/_cfg/files-manifest.csv +286 -242
  5. package/.bmad/_cfg/ides/claude-code.yaml +1 -1
  6. package/.bmad/_cfg/manifest.yaml +5 -3
  7. package/.bmad/_cfg/task-manifest.csv +1 -0
  8. package/.bmad/_cfg/workflow-manifest.csv +37 -38
  9. package/.bmad/bmm/agents/analyst.md +40 -41
  10. package/.bmad/bmm/agents/{frame-expert.md → analyst.md.bak} +23 -16
  11. package/.bmad/bmm/agents/architect.md +34 -42
  12. package/.bmad/bmm/agents/dev.md +38 -34
  13. package/.bmad/bmm/agents/pm.md +34 -46
  14. package/.bmad/bmm/agents/quick-flow-solo-dev.md +64 -0
  15. package/.bmad/bmm/agents/sm.md +47 -53
  16. package/.bmad/bmm/agents/tea.md +41 -42
  17. package/.bmad/bmm/agents/tech-writer.md +37 -39
  18. package/.bmad/bmm/agents/ux-designer.md +42 -41
  19. package/.bmad/bmm/config.yaml +7 -5
  20. package/.bmad/bmm/data/README.md +29 -0
  21. package/.bmad/bmm/data/project-context-template.md +40 -0
  22. package/.bmad/bmm/docs/README.md +48 -10
  23. package/.bmad/bmm/docs/agents-guide.md +80 -53
  24. package/.bmad/bmm/docs/bmad-quick-flow.md +528 -0
  25. package/.bmad/bmm/docs/brownfield-guide.md +25 -39
  26. package/.bmad/bmm/docs/enterprise-agentic-development.md +3 -3
  27. package/.bmad/bmm/docs/faq.md +6 -39
  28. package/.bmad/bmm/docs/glossary.md +12 -25
  29. package/.bmad/bmm/docs/images/README.md +37 -0
  30. package/.bmad/bmm/docs/images/workflow-method-greenfield.excalidraw +5034 -0
  31. package/.bmad/bmm/docs/images/workflow-method-greenfield.svg +4 -0
  32. package/.bmad/bmm/docs/quick-flow-solo-dev.md +337 -0
  33. package/.bmad/bmm/docs/quick-spec-flow.md +5 -5
  34. package/.bmad/bmm/docs/quick-start.md +15 -25
  35. package/.bmad/bmm/docs/scale-adaptive-system.md +11 -5
  36. package/.bmad/bmm/docs/test-architecture.md +90 -24
  37. package/.bmad/bmm/docs/troubleshooting.md +680 -0
  38. package/.bmad/bmm/docs/workflow-document-project-reference.md +1 -1
  39. package/.bmad/bmm/docs/workflows-analysis.md +36 -140
  40. package/.bmad/bmm/docs/workflows-implementation.md +182 -157
  41. package/.bmad/bmm/docs/workflows-planning.md +51 -212
  42. package/.bmad/bmm/docs/workflows-solutioning.md +26 -71
  43. package/.bmad/bmm/tasks/daily-standup.xml +85 -0
  44. package/.bmad/bmm/teams/default-party.csv +15 -14
  45. package/.bmad/bmm/teams/team-fullstack.yaml +0 -1
  46. package/.bmad/bmm/testarch/knowledge/api-request.md +303 -0
  47. package/.bmad/bmm/testarch/knowledge/auth-session.md +356 -0
  48. package/.bmad/bmm/testarch/knowledge/burn-in.md +273 -0
  49. package/.bmad/bmm/testarch/knowledge/ci-burn-in.md +1 -1
  50. package/.bmad/bmm/testarch/knowledge/file-utils.md +260 -0
  51. package/.bmad/bmm/testarch/knowledge/fixtures-composition.md +382 -0
  52. package/.bmad/bmm/testarch/knowledge/intercept-network-call.md +280 -0
  53. package/.bmad/bmm/testarch/knowledge/log.md +294 -0
  54. package/.bmad/bmm/testarch/knowledge/network-error-monitor.md +272 -0
  55. package/.bmad/bmm/testarch/knowledge/network-recorder.md +265 -0
  56. package/.bmad/bmm/testarch/knowledge/overview.md +284 -0
  57. package/.bmad/bmm/testarch/knowledge/recurse.md +296 -0
  58. package/.bmad/bmm/testarch/tea-index.csv +11 -0
  59. package/.bmad/bmm/workflows/1-analysis/product-brief/product-brief.template.md +8 -0
  60. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-01-init.md +192 -0
  61. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-01b-continue.md +167 -0
  62. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-02-vision.md +203 -0
  63. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-03-users.md +206 -0
  64. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-04-metrics.md +209 -0
  65. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-05-scope.md +223 -0
  66. package/.bmad/bmm/workflows/1-analysis/product-brief/steps/step-06-complete.md +199 -0
  67. package/.bmad/bmm/workflows/1-analysis/product-brief/workflow.md +58 -0
  68. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-01-init.md +136 -0
  69. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-02-domain-analysis.md +228 -0
  70. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-03-competitive-landscape.md +237 -0
  71. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-04-regulatory-focus.md +205 -0
  72. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-05-technical-trends.md +233 -0
  73. package/.bmad/bmm/workflows/1-analysis/research/domain-steps/step-06-research-synthesis.md +442 -0
  74. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-01-init.md +181 -0
  75. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-02-customer-behavior.md +236 -0
  76. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-02-customer-insights.md +199 -0
  77. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-03-customer-pain-points.md +248 -0
  78. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-04-customer-decisions.md +258 -0
  79. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-05-competitive-analysis.md +176 -0
  80. package/.bmad/bmm/workflows/1-analysis/research/market-steps/step-06-research-completion.md +474 -0
  81. package/.bmad/bmm/workflows/1-analysis/research/research.template.md +15 -0
  82. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-01-init.md +136 -0
  83. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-02-technical-overview.md +238 -0
  84. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-03-integration-patterns.md +247 -0
  85. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-04-architectural-patterns.md +201 -0
  86. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-05-implementation-research.md +238 -0
  87. package/.bmad/bmm/workflows/1-analysis/research/technical-steps/step-06-research-synthesis.md +485 -0
  88. package/.bmad/bmm/workflows/1-analysis/research/workflow.md +204 -0
  89. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-01-init.md +159 -0
  90. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-01b-continue.md +126 -0
  91. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-02-discovery.md +209 -0
  92. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-03-core-experience.md +215 -0
  93. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-04-emotional-response.md +218 -0
  94. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-05-inspiration.md +233 -0
  95. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-06-design-system.md +251 -0
  96. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-07-defining-experience.md +253 -0
  97. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-08-visual-foundation.md +223 -0
  98. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-09-design-directions.md +223 -0
  99. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-10-user-journeys.md +240 -0
  100. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-11-component-strategy.md +247 -0
  101. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-12-ux-patterns.md +236 -0
  102. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-13-responsive-accessibility.md +263 -0
  103. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/steps/step-14-complete.md +226 -0
  104. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/ux-design-template.md +6 -138
  105. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/workflow.md +59 -0
  106. package/.bmad/bmm/workflows/2-plan-workflows/prd/prd-template.md +12 -200
  107. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-01-init.md +243 -0
  108. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-01b-continue.md +165 -0
  109. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-02-discovery.md +420 -0
  110. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-03-success.md +289 -0
  111. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-04-journeys.md +290 -0
  112. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-05-domain.md +270 -0
  113. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-06-innovation.md +261 -0
  114. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-07-project-type.md +257 -0
  115. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-08-scoping.md +298 -0
  116. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-09-functional.md +269 -0
  117. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-10-nonfunctional.md +293 -0
  118. package/.bmad/bmm/workflows/2-plan-workflows/prd/steps/step-11-complete.md +223 -0
  119. package/.bmad/bmm/workflows/2-plan-workflows/prd/workflow.md +61 -0
  120. package/.bmad/bmm/workflows/3-solutioning/architecture/architecture-decision-template.md +13 -0
  121. package/.bmad/bmm/workflows/3-solutioning/architecture/data/domain-complexity.csv +11 -0
  122. package/.bmad/bmm/workflows/3-solutioning/architecture/data/project-types.csv +7 -0
  123. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-01-init.md +194 -0
  124. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-01b-continue.md +163 -0
  125. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-02-context.md +223 -0
  126. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-03-starter.md +330 -0
  127. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-04-decisions.md +317 -0
  128. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-05-patterns.md +358 -0
  129. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-06-structure.md +378 -0
  130. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-07-validation.md +358 -0
  131. package/.bmad/bmm/workflows/3-solutioning/architecture/steps/step-08-complete.md +351 -0
  132. package/.bmad/bmm/workflows/3-solutioning/architecture/workflow.md +49 -0
  133. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-01-validate-prerequisites.md +258 -0
  134. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-02-design-epics.md +232 -0
  135. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-03-create-stories.md +271 -0
  136. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/steps/step-04-final-validation.md +144 -0
  137. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/templates/epics-template.md +57 -0
  138. package/.bmad/bmm/workflows/3-solutioning/create-epics-and-stories/workflow.md +58 -0
  139. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-01-document-discovery.md +189 -0
  140. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-02-prd-analysis.md +177 -0
  141. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-03-epic-coverage-validation.md +178 -0
  142. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-04-ux-alignment.md +138 -0
  143. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-05-epic-quality-review.md +251 -0
  144. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/steps/step-06-final-assessment.md +132 -0
  145. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/templates/readiness-report-template.md +4 -0
  146. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/workflow.md +54 -0
  147. package/.bmad/bmm/workflows/4-implementation/code-review/checklist.md +2 -1
  148. package/.bmad/bmm/workflows/4-implementation/code-review/instructions.xml +224 -0
  149. package/.bmad/bmm/workflows/4-implementation/code-review/workflow.yaml +4 -11
  150. package/.bmad/bmm/workflows/4-implementation/create-story/checklist.md +332 -214
  151. package/.bmad/bmm/workflows/4-implementation/create-story/instructions.xml +354 -0
  152. package/.bmad/bmm/workflows/4-implementation/create-story/workflow.yaml +21 -34
  153. package/.bmad/bmm/workflows/4-implementation/dev-story/checklist.md +65 -23
  154. package/.bmad/bmm/workflows/4-implementation/dev-story/instructions.xml +406 -0
  155. package/.bmad/bmm/workflows/4-implementation/dev-story/workflow.yaml +6 -37
  156. package/.bmad/bmm/workflows/4-implementation/retrospective/instructions.md +3 -3
  157. package/.bmad/bmm/workflows/4-implementation/sprint-planning/instructions.md +19 -21
  158. package/.bmad/bmm/workflows/4-implementation/sprint-planning/sprint-status-template.yaml +11 -10
  159. package/.bmad/bmm/workflows/4-implementation/sprint-planning/workflow.yaml +2 -0
  160. package/.bmad/bmm/workflows/4-implementation/sprint-status/instructions.md +174 -0
  161. package/.bmad/bmm/workflows/4-implementation/sprint-status/workflow.yaml +34 -0
  162. package/.bmad/bmm/workflows/bmad-quick-flow/create-tech-spec/instructions.md +115 -0
  163. package/.bmad/bmm/workflows/bmad-quick-flow/create-tech-spec/workflow.yaml +25 -0
  164. package/.bmad/bmm/workflows/bmad-quick-flow/quick-dev/checklist.md +25 -0
  165. package/.bmad/bmm/workflows/bmad-quick-flow/quick-dev/instructions.md +202 -0
  166. package/.bmad/bmm/workflows/bmad-quick-flow/quick-dev/workflow.yaml +32 -0
  167. package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-dataflow/instructions.md +7 -8
  168. package/.bmad/bmm/workflows/diagrams/create-dataflow/workflow.yaml +26 -0
  169. package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-diagram/instructions.md +9 -10
  170. package/.bmad/bmm/workflows/diagrams/create-diagram/workflow.yaml +26 -0
  171. package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-flowchart/instructions.md +4 -5
  172. package/.bmad/bmm/workflows/diagrams/create-flowchart/workflow.yaml +26 -0
  173. package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-wireframe/instructions.md +3 -3
  174. package/.bmad/bmm/workflows/diagrams/create-wireframe/workflow.yaml +26 -0
  175. package/.bmad/bmm/workflows/document-project/instructions.md +1 -1
  176. package/.bmad/bmm/workflows/document-project/workflows/deep-dive-instructions.md +2 -2
  177. package/.bmad/bmm/workflows/generate-project-context/project-context-template.md +20 -0
  178. package/.bmad/bmm/workflows/generate-project-context/steps/step-01-discover.md +193 -0
  179. package/.bmad/bmm/workflows/generate-project-context/steps/step-02-generate.md +317 -0
  180. package/.bmad/bmm/workflows/generate-project-context/steps/step-03-complete.md +277 -0
  181. package/.bmad/bmm/workflows/generate-project-context/workflow.md +48 -0
  182. package/.bmad/bmm/workflows/testarch/atdd/atdd-checklist-template.md +1 -1
  183. package/.bmad/bmm/workflows/testarch/atdd/instructions.md +23 -3
  184. package/.bmad/bmm/workflows/testarch/automate/instructions.md +23 -2
  185. package/.bmad/bmm/workflows/testarch/ci/checklist.md +1 -1
  186. package/.bmad/bmm/workflows/testarch/ci/github-actions-template.yaml +36 -3
  187. package/.bmad/bmm/workflows/testarch/ci/gitlab-ci-template.yaml +25 -4
  188. package/.bmad/bmm/workflows/testarch/ci/instructions.md +20 -3
  189. package/.bmad/bmm/workflows/testarch/framework/instructions.md +27 -1
  190. package/.bmad/bmm/workflows/testarch/test-design/instructions.md +8 -2
  191. package/.bmad/bmm/workflows/testarch/test-review/instructions.md +29 -9
  192. package/.bmad/bmm/workflows/workflow-status/init/instructions.md +66 -54
  193. package/.bmad/bmm/workflows/workflow-status/instructions.md +11 -4
  194. package/.bmad/bmm/workflows/workflow-status/paths/enterprise-brownfield.yaml +22 -38
  195. package/.bmad/bmm/workflows/workflow-status/paths/enterprise-greenfield.yaml +6 -22
  196. package/.bmad/bmm/workflows/workflow-status/paths/method-brownfield.yaml +6 -22
  197. package/.bmad/bmm/workflows/workflow-status/paths/method-greenfield.yaml +6 -23
  198. package/.bmad/core/agents/bmad-master.md +12 -17
  199. package/.bmad/core/agents/bmad-web-orchestrator.agent.xml +1 -1
  200. package/.bmad/core/config.yaml +11 -0
  201. package/.bmad/core/resources/excalidraw/README.md +160 -0
  202. package/.bmad/core/resources/excalidraw/library-loader.md +50 -0
  203. package/.bmad/core/tasks/advanced-elicitation-methods.csv +51 -21
  204. package/.bmad/core/tasks/advanced-elicitation.xml +18 -8
  205. package/.bmad/core/tasks/workflow.xml +36 -71
  206. package/.bmad/core/workflows/brainstorming/brain-methods.csv +62 -36
  207. package/.bmad/core/workflows/brainstorming/steps/step-01-session-setup.md +196 -0
  208. package/.bmad/core/workflows/brainstorming/steps/step-01b-continue.md +121 -0
  209. package/.bmad/core/workflows/brainstorming/steps/step-02a-user-selected.md +224 -0
  210. package/.bmad/core/workflows/brainstorming/steps/step-02b-ai-recommended.md +236 -0
  211. package/.bmad/core/workflows/brainstorming/steps/step-02c-random-selection.md +208 -0
  212. package/.bmad/core/workflows/brainstorming/steps/step-02d-progressive-flow.md +263 -0
  213. package/.bmad/core/workflows/brainstorming/steps/step-03-technique-execution.md +339 -0
  214. package/.bmad/core/workflows/brainstorming/steps/step-04-idea-organization.md +302 -0
  215. package/.bmad/core/workflows/brainstorming/template.md +13 -104
  216. package/.bmad/core/workflows/brainstorming/workflow.md +51 -0
  217. package/.bmad/core/workflows/party-mode/instructions.md.bak +205 -0
  218. package/.bmad/core/workflows/party-mode/steps/step-01-agent-loading.md +140 -0
  219. package/.bmad/core/workflows/party-mode/steps/step-02-discussion-orchestration.md +205 -0
  220. package/.bmad/core/workflows/party-mode/steps/step-03-graceful-exit.md +158 -0
  221. package/.bmad/core/workflows/party-mode/workflow.md +225 -0
  222. package/.claude/commands/bmad/bmm/agents/{frame-expert.md → quick-flow-solo-dev.md} +3 -3
  223. package/.claude/commands/bmad/bmm/workflows/check-implementation-readiness.md +5 -0
  224. package/.claude/commands/bmad/bmm/workflows/code-review.md +1 -1
  225. package/.claude/commands/bmad/bmm/workflows/create-architecture.md +5 -0
  226. package/.claude/commands/bmad/bmm/workflows/create-epics-stories.md +5 -0
  227. package/.claude/commands/bmad/bmm/workflows/{create-dataflow.md → create-excalidraw-dataflow.md} +2 -2
  228. package/.claude/commands/bmad/bmm/workflows/{create-diagram.md → create-excalidraw-diagram.md} +2 -2
  229. package/.claude/commands/bmad/bmm/workflows/{create-flowchart.md → create-excalidraw-flowchart.md} +2 -2
  230. package/.claude/commands/bmad/bmm/workflows/{create-wireframe.md → create-excalidraw-wireframe.md} +2 -2
  231. package/.claude/commands/bmad/bmm/workflows/create-prd.md +5 -0
  232. package/.claude/commands/bmad/bmm/workflows/create-product-brief.md +5 -0
  233. package/.claude/commands/bmad/bmm/workflows/create-story.md +1 -1
  234. package/.claude/commands/bmad/bmm/workflows/create-tech-spec.md +13 -0
  235. package/.claude/commands/bmad/bmm/workflows/create-ux-design.md +2 -10
  236. package/.claude/commands/bmad/bmm/workflows/generate-project-context.md +5 -0
  237. package/.claude/commands/bmad/bmm/workflows/{domain-research.md → quick-dev.md} +3 -3
  238. package/.claude/commands/bmad/bmm/workflows/research.md +2 -10
  239. package/.claude/commands/bmad/bmm/workflows/{story-context.md → sprint-status.md} +3 -3
  240. package/.claude/commands/bmad/bmm/workflows/testarch-atdd.md +13 -0
  241. package/.claude/commands/bmad/bmm/workflows/testarch-automate.md +13 -0
  242. package/.claude/commands/bmad/bmm/workflows/testarch-ci.md +13 -0
  243. package/.claude/commands/bmad/bmm/workflows/testarch-framework.md +13 -0
  244. package/.claude/commands/bmad/bmm/workflows/testarch-nfr.md +13 -0
  245. package/.claude/commands/bmad/bmm/workflows/{prd.md → testarch-test-design.md} +3 -3
  246. package/.claude/commands/bmad/bmm/workflows/testarch-test-review.md +13 -0
  247. package/.claude/commands/bmad/bmm/workflows/testarch-trace.md +13 -0
  248. package/.claude/commands/bmad/core/workflows/brainstorming-session.md +5 -0
  249. package/.claude/config/tts-speech-rate.txt +1 -0
  250. package/.claude/github-star-reminder.txt +1 -1
  251. package/.claude/hooks/audio-processor.sh +12 -3
  252. package/.claude/hooks/piper-installer.sh +17 -0
  253. package/.claude/hooks/play-tts-piper.sh +4 -0
  254. package/.claude/hooks/termux-installer.sh +224 -0
  255. package/.clawdbot/README.md +105 -0
  256. package/.clawdbot/skill/SKILL.md +432 -0
  257. package/README.md +167 -11
  258. package/RELEASE_NOTES.md +255 -249
  259. package/package.json +4 -2
  260. package/src/installer.js +75 -21
  261. package/.bmad/bmm/workflows/1-analysis/brainstorm-project/instructions.md +0 -112
  262. package/.bmad/bmm/workflows/1-analysis/brainstorm-project/project-context.md +0 -25
  263. package/.bmad/bmm/workflows/1-analysis/brainstorm-project/workflow.yaml +0 -26
  264. package/.bmad/bmm/workflows/1-analysis/domain-research/instructions.md +0 -425
  265. package/.bmad/bmm/workflows/1-analysis/domain-research/template.md +0 -180
  266. package/.bmad/bmm/workflows/1-analysis/domain-research/workflow.yaml +0 -28
  267. package/.bmad/bmm/workflows/1-analysis/product-brief/checklist.md +0 -115
  268. package/.bmad/bmm/workflows/1-analysis/product-brief/instructions.md +0 -524
  269. package/.bmad/bmm/workflows/1-analysis/product-brief/template.md +0 -181
  270. package/.bmad/bmm/workflows/1-analysis/product-brief/workflow.yaml +0 -45
  271. package/.bmad/bmm/workflows/1-analysis/research/checklist-deep-prompt.md +0 -144
  272. package/.bmad/bmm/workflows/1-analysis/research/checklist-technical.md +0 -249
  273. package/.bmad/bmm/workflows/1-analysis/research/checklist.md +0 -299
  274. package/.bmad/bmm/workflows/1-analysis/research/claude-code/injections.yaml +0 -114
  275. package/.bmad/bmm/workflows/1-analysis/research/instructions-deep-prompt.md +0 -438
  276. package/.bmad/bmm/workflows/1-analysis/research/instructions-market.md +0 -675
  277. package/.bmad/bmm/workflows/1-analysis/research/instructions-router.md +0 -134
  278. package/.bmad/bmm/workflows/1-analysis/research/instructions-technical.md +0 -534
  279. package/.bmad/bmm/workflows/1-analysis/research/template-deep-prompt.md +0 -94
  280. package/.bmad/bmm/workflows/1-analysis/research/template-market.md +0 -347
  281. package/.bmad/bmm/workflows/1-analysis/research/template-technical.md +0 -245
  282. package/.bmad/bmm/workflows/1-analysis/research/workflow.yaml +0 -44
  283. package/.bmad/bmm/workflows/2-plan-workflows/create-epics-and-stories/epics-template.md +0 -80
  284. package/.bmad/bmm/workflows/2-plan-workflows/create-epics-and-stories/instructions.md +0 -616
  285. package/.bmad/bmm/workflows/2-plan-workflows/create-epics-and-stories/workflow.yaml +0 -53
  286. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/checklist.md +0 -310
  287. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/instructions.md +0 -1308
  288. package/.bmad/bmm/workflows/2-plan-workflows/create-ux-design/workflow.yaml +0 -61
  289. package/.bmad/bmm/workflows/2-plan-workflows/prd/checklist.md +0 -346
  290. package/.bmad/bmm/workflows/2-plan-workflows/prd/instructions.md +0 -703
  291. package/.bmad/bmm/workflows/2-plan-workflows/prd/workflow.yaml +0 -52
  292. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/checklist.md +0 -217
  293. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/epics-template.md +0 -74
  294. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/instructions-generate-stories.md +0 -436
  295. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/instructions.md +0 -980
  296. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/tech-spec-template.md +0 -181
  297. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/user-story-template.md +0 -90
  298. package/.bmad/bmm/workflows/2-plan-workflows/tech-spec/workflow.yaml +0 -58
  299. package/.bmad/bmm/workflows/3-solutioning/architecture/architecture-patterns.yaml +0 -321
  300. package/.bmad/bmm/workflows/3-solutioning/architecture/architecture-template.md +0 -103
  301. package/.bmad/bmm/workflows/3-solutioning/architecture/checklist.md +0 -240
  302. package/.bmad/bmm/workflows/3-solutioning/architecture/decision-catalog.yaml +0 -222
  303. package/.bmad/bmm/workflows/3-solutioning/architecture/instructions.md +0 -768
  304. package/.bmad/bmm/workflows/3-solutioning/architecture/pattern-categories.csv +0 -13
  305. package/.bmad/bmm/workflows/3-solutioning/architecture/workflow.yaml +0 -55
  306. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/checklist.md +0 -169
  307. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/instructions.md +0 -332
  308. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/template.md +0 -146
  309. package/.bmad/bmm/workflows/3-solutioning/implementation-readiness/workflow.yaml +0 -62
  310. package/.bmad/bmm/workflows/4-implementation/code-review/backlog_template.md +0 -12
  311. package/.bmad/bmm/workflows/4-implementation/code-review/instructions.md +0 -398
  312. package/.bmad/bmm/workflows/4-implementation/create-story/instructions.md +0 -256
  313. package/.bmad/bmm/workflows/4-implementation/dev-story/instructions.md +0 -267
  314. package/.bmad/bmm/workflows/4-implementation/epic-tech-context/checklist.md +0 -17
  315. package/.bmad/bmm/workflows/4-implementation/epic-tech-context/instructions.md +0 -164
  316. package/.bmad/bmm/workflows/4-implementation/epic-tech-context/template.md +0 -76
  317. package/.bmad/bmm/workflows/4-implementation/epic-tech-context/workflow.yaml +0 -57
  318. package/.bmad/bmm/workflows/4-implementation/story-context/checklist.md +0 -16
  319. package/.bmad/bmm/workflows/4-implementation/story-context/context-template.xml +0 -34
  320. package/.bmad/bmm/workflows/4-implementation/story-context/instructions.md +0 -209
  321. package/.bmad/bmm/workflows/4-implementation/story-context/workflow.yaml +0 -61
  322. package/.bmad/bmm/workflows/4-implementation/story-done/instructions.md +0 -111
  323. package/.bmad/bmm/workflows/4-implementation/story-done/workflow.yaml +0 -26
  324. package/.bmad/bmm/workflows/4-implementation/story-ready/instructions.md +0 -117
  325. package/.bmad/bmm/workflows/4-implementation/story-ready/workflow.yaml +0 -23
  326. package/.bmad/bmm/workflows/frame-expert/create-dataflow/workflow.yaml +0 -23
  327. package/.bmad/bmm/workflows/frame-expert/create-diagram/workflow.yaml +0 -24
  328. package/.bmad/bmm/workflows/frame-expert/create-flowchart/workflow.yaml +0 -27
  329. package/.bmad/bmm/workflows/frame-expert/create-wireframe/workflow.yaml +0 -23
  330. package/.bmad/bmm/workflows/workflow-status/paths/game-design.yaml +0 -52
  331. package/.bmad/bmm/workflows/workflow-status/paths/quick-flow-brownfield.yaml +0 -58
  332. package/.bmad/bmm/workflows/workflow-status/paths/quick-flow-greenfield.yaml +0 -47
  333. package/.claude/commands/bmad/bmm/workflows/architecture.md +0 -13
  334. package/.claude/commands/bmad/bmm/workflows/brainstorm-project.md +0 -13
  335. package/.claude/commands/bmad/bmm/workflows/create-epics-and-stories.md +0 -13
  336. package/.claude/commands/bmad/bmm/workflows/epic-tech-context.md +0 -13
  337. package/.claude/commands/bmad/bmm/workflows/implementation-readiness.md +0 -13
  338. package/.claude/commands/bmad/bmm/workflows/product-brief.md +0 -13
  339. package/.claude/commands/bmad/bmm/workflows/story-done.md +0 -13
  340. package/.claude/commands/bmad/bmm/workflows/story-ready.md +0 -13
  341. package/.claude/commands/bmad/bmm/workflows/tech-spec.md +0 -13
  342. /package/.bmad/bmm/{workflows/techdoc → data}/documentation-standards.md +0 -0
  343. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/_shared/excalidraw-library.json +0 -0
  344. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/_shared/excalidraw-templates.yaml +0 -0
  345. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-dataflow/checklist.md +0 -0
  346. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-diagram/checklist.md +0 -0
  347. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-flowchart/checklist.md +0 -0
  348. /package/.bmad/bmm/workflows/{frame-expert → diagrams}/create-wireframe/checklist.md +0 -0
  349. /package/.bmad/{bmm/workflows/frame-expert/_shared → core/resources/excalidraw}/excalidraw-helpers.md +0 -0
  350. /package/.bmad/{bmm/workflows/frame-expert/_shared → core/resources/excalidraw}/validate-json-instructions.md +0 -0
@@ -0,0 +1,280 @@
1
+ # Intercept Network Call Utility
2
+
3
+ ## Principle
4
+
5
+ Intercept network requests with a single declarative call that returns a Promise. Automatically parse JSON responses, support both spy (observe) and stub (mock) patterns, and use powerful glob pattern matching for URL filtering.
6
+
7
+ ## Rationale
8
+
9
+ Vanilla Playwright's network interception requires multiple steps:
10
+
11
+ - `page.route()` to setup, `page.waitForResponse()` to capture
12
+ - Manual JSON parsing
13
+ - Verbose syntax for conditional handling
14
+ - Complex filter predicates
15
+
16
+ The `interceptNetworkCall` utility provides:
17
+
18
+ - **Single declarative call**: Setup and wait in one statement
19
+ - **Automatic JSON parsing**: Response pre-parsed, strongly typed
20
+ - **Flexible URL patterns**: Glob matching with picomatch
21
+ - **Spy or stub modes**: Observe real traffic or mock responses
22
+ - **Concise API**: Reduces boilerplate by 60-70%
23
+
24
+ ## Pattern Examples
25
+
26
+ ### Example 1: Spy on Network (Observe Real Traffic)
27
+
28
+ **Context**: Capture and inspect real API responses for validation.
29
+
30
+ **Implementation**:
31
+
32
+ ```typescript
33
+ import { test } from '@seontechnologies/playwright-utils/intercept-network-call/fixtures';
34
+
35
+ test('should spy on users API', async ({ page, interceptNetworkCall }) => {
36
+ // Setup interception BEFORE navigation
37
+ const usersCall = interceptNetworkCall({
38
+ url: '**/api/users', // Glob pattern
39
+ });
40
+
41
+ await page.goto('/dashboard');
42
+
43
+ // Wait for response and access parsed data
44
+ const { responseJson, status } = await usersCall;
45
+
46
+ expect(status).toBe(200);
47
+ expect(responseJson).toHaveLength(10);
48
+ expect(responseJson[0]).toHaveProperty('name');
49
+ });
50
+ ```
51
+
52
+ **Key Points**:
53
+
54
+ - Intercept before navigation (critical for race-free tests)
55
+ - Returns Promise with `{ responseJson, status, requestBody }`
56
+ - Glob patterns (`**` matches any path segment)
57
+ - JSON automatically parsed
58
+
59
+ ### Example 2: Stub Network (Mock Response)
60
+
61
+ **Context**: Mock API responses for testing UI behavior without backend.
62
+
63
+ **Implementation**:
64
+
65
+ ```typescript
66
+ test('should stub users API', async ({ page, interceptNetworkCall }) => {
67
+ const mockUsers = [
68
+ { id: 1, name: 'Test User 1' },
69
+ { id: 2, name: 'Test User 2' },
70
+ ];
71
+
72
+ const usersCall = interceptNetworkCall({
73
+ url: '**/api/users',
74
+ fulfillResponse: {
75
+ status: 200,
76
+ body: mockUsers,
77
+ },
78
+ });
79
+
80
+ await page.goto('/dashboard');
81
+ await usersCall;
82
+
83
+ // UI shows mocked data
84
+ await expect(page.getByText('Test User 1')).toBeVisible();
85
+ await expect(page.getByText('Test User 2')).toBeVisible();
86
+ });
87
+ ```
88
+
89
+ **Key Points**:
90
+
91
+ - `fulfillResponse` mocks the API
92
+ - No backend needed
93
+ - Test UI logic in isolation
94
+ - Status code and body fully controllable
95
+
96
+ ### Example 3: Conditional Response Handling
97
+
98
+ **Context**: Different responses based on request method or parameters.
99
+
100
+ **Implementation**:
101
+
102
+ ```typescript
103
+ test('conditional mocking', async ({ page, interceptNetworkCall }) => {
104
+ await interceptNetworkCall({
105
+ url: '**/api/data',
106
+ handler: async (route, request) => {
107
+ if (request.method() === 'POST') {
108
+ // Mock POST success
109
+ await route.fulfill({
110
+ status: 201,
111
+ body: JSON.stringify({ id: 'new-id', success: true }),
112
+ });
113
+ } else if (request.method() === 'GET') {
114
+ // Mock GET with data
115
+ await route.fulfill({
116
+ status: 200,
117
+ body: JSON.stringify([{ id: 1, name: 'Item' }]),
118
+ });
119
+ } else {
120
+ // Let other methods through
121
+ await route.continue();
122
+ }
123
+ },
124
+ });
125
+
126
+ await page.goto('/data-page');
127
+ });
128
+ ```
129
+
130
+ **Key Points**:
131
+
132
+ - `handler` function for complex logic
133
+ - Access full `route` and `request` objects
134
+ - Can mock, continue, or abort
135
+ - Flexible for advanced scenarios
136
+
137
+ ### Example 4: Error Simulation
138
+
139
+ **Context**: Testing error handling in UI when API fails.
140
+
141
+ **Implementation**:
142
+
143
+ ```typescript
144
+ test('should handle API errors gracefully', async ({ page, interceptNetworkCall }) => {
145
+ // Simulate 500 error
146
+ const errorCall = interceptNetworkCall({
147
+ url: '**/api/users',
148
+ fulfillResponse: {
149
+ status: 500,
150
+ body: { error: 'Internal Server Error' },
151
+ },
152
+ });
153
+
154
+ await page.goto('/dashboard');
155
+ await errorCall;
156
+
157
+ // Verify UI shows error state
158
+ await expect(page.getByText('Failed to load users')).toBeVisible();
159
+ await expect(page.getByTestId('retry-button')).toBeVisible();
160
+ });
161
+
162
+ // Simulate network timeout
163
+ test('should handle timeout', async ({ page, interceptNetworkCall }) => {
164
+ await interceptNetworkCall({
165
+ url: '**/api/slow',
166
+ handler: async (route) => {
167
+ // Never respond - simulates timeout
168
+ await new Promise(() => {});
169
+ },
170
+ });
171
+
172
+ await page.goto('/slow-page');
173
+
174
+ // UI should show timeout error
175
+ await expect(page.getByText('Request timed out')).toBeVisible({ timeout: 10000 });
176
+ });
177
+ ```
178
+
179
+ **Key Points**:
180
+
181
+ - Mock error statuses (4xx, 5xx)
182
+ - Test timeout scenarios
183
+ - Validate error UI states
184
+ - No real failures needed
185
+
186
+ ### Example 5: Multiple Intercepts (Order Matters!)
187
+
188
+ **Context**: Intercepting different endpoints in same test - setup order is critical.
189
+
190
+ **Implementation**:
191
+
192
+ ```typescript
193
+ test('multiple intercepts', async ({ page, interceptNetworkCall }) => {
194
+ // ✅ CORRECT: Setup all intercepts BEFORE navigation
195
+ const usersCall = interceptNetworkCall({ url: '**/api/users' });
196
+ const productsCall = interceptNetworkCall({ url: '**/api/products' });
197
+ const ordersCall = interceptNetworkCall({ url: '**/api/orders' });
198
+
199
+ // THEN navigate
200
+ await page.goto('/dashboard');
201
+
202
+ // Wait for all (or specific ones)
203
+ const [users, products] = await Promise.all([usersCall, productsCall]);
204
+
205
+ expect(users.responseJson).toHaveLength(10);
206
+ expect(products.responseJson).toHaveLength(50);
207
+ });
208
+ ```
209
+
210
+ **Key Points**:
211
+
212
+ - Setup all intercepts before triggering actions
213
+ - Use `Promise.all()` to wait for multiple calls
214
+ - Order: intercept → navigate → await
215
+ - Prevents race conditions
216
+
217
+ ## URL Pattern Matching
218
+
219
+ **Supported glob patterns:**
220
+
221
+ ```typescript
222
+ '**/api/users'; // Any path ending with /api/users
223
+ '/api/users'; // Exact match
224
+ '**/users/*'; // Any users sub-path
225
+ '**/api/{users,products}'; // Either users or products
226
+ '**/api/users?id=*'; // With query params
227
+ ```
228
+
229
+ **Uses picomatch library** - same pattern syntax as Playwright's `page.route()` but cleaner API.
230
+
231
+ ## Comparison with Vanilla Playwright
232
+
233
+ | Vanilla Playwright | intercept-network-call |
234
+ | ----------------------------------------------------------- | ------------------------------------------------------------ |
235
+ | `await page.route('/api/users', route => route.continue())` | `const call = interceptNetworkCall({ url: '**/api/users' })` |
236
+ | `const resp = await page.waitForResponse('/api/users')` | (Combined in single statement) |
237
+ | `const json = await resp.json()` | `const { responseJson } = await call` |
238
+ | `const status = resp.status()` | `const { status } = await call` |
239
+ | Complex filter predicates | Simple glob patterns |
240
+
241
+ **Reduction:** ~5-7 lines → ~2-3 lines per interception
242
+
243
+ ## Related Fragments
244
+
245
+ - `network-first.md` - Core pattern: intercept before navigate
246
+ - `network-recorder.md` - HAR-based offline testing
247
+ - `overview.md` - Fixture composition basics
248
+
249
+ ## Anti-Patterns
250
+
251
+ **❌ Intercepting after navigation:**
252
+
253
+ ```typescript
254
+ await page.goto('/dashboard'); // Navigation starts
255
+ const usersCall = interceptNetworkCall({ url: '**/api/users' }); // Too late!
256
+ ```
257
+
258
+ **✅ Intercept before navigate:**
259
+
260
+ ```typescript
261
+ const usersCall = interceptNetworkCall({ url: '**/api/users' }); // First
262
+ await page.goto('/dashboard'); // Then navigate
263
+ const { responseJson } = await usersCall; // Then await
264
+ ```
265
+
266
+ **❌ Ignoring the returned Promise:**
267
+
268
+ ```typescript
269
+ interceptNetworkCall({ url: '**/api/users' }); // Not awaited!
270
+ await page.goto('/dashboard');
271
+ // No deterministic wait - race condition
272
+ ```
273
+
274
+ **✅ Always await the intercept:**
275
+
276
+ ```typescript
277
+ const usersCall = interceptNetworkCall({ url: '**/api/users' });
278
+ await page.goto('/dashboard');
279
+ await usersCall; // Deterministic wait
280
+ ```
@@ -0,0 +1,294 @@
1
+ # Log Utility
2
+
3
+ ## Principle
4
+
5
+ Use structured logging that integrates with Playwright's test reports. Support object logging, test step decoration, and multiple log levels (info, step, success, warning, error, debug).
6
+
7
+ ## Rationale
8
+
9
+ Console.log in Playwright tests has limitations:
10
+
11
+ - Not visible in HTML reports
12
+ - No test step integration
13
+ - No structured output
14
+ - Lost in terminal noise during CI
15
+
16
+ The `log` utility provides:
17
+
18
+ - **Report integration**: Logs appear in Playwright HTML reports
19
+ - **Test step decoration**: `log.step()` creates collapsible steps in UI
20
+ - **Object logging**: Automatically formats objects/arrays
21
+ - **Multiple levels**: info, step, success, warning, error, debug
22
+ - **Optional console**: Can disable console output but keep report logs
23
+
24
+ ## Pattern Examples
25
+
26
+ ### Example 1: Basic Logging Levels
27
+
28
+ **Context**: Log different types of messages throughout test execution.
29
+
30
+ **Implementation**:
31
+
32
+ ```typescript
33
+ import { log } from '@seontechnologies/playwright-utils';
34
+
35
+ test('logging demo', async ({ page }) => {
36
+ await log.step('Navigate to login page');
37
+ await page.goto('/login');
38
+
39
+ await log.info('Entering credentials');
40
+ await page.fill('#username', 'testuser');
41
+
42
+ await log.success('Login successful');
43
+
44
+ await log.warning('Rate limit approaching');
45
+
46
+ await log.debug({ userId: '123', sessionId: 'abc' });
47
+
48
+ // Errors still throw but get logged first
49
+ try {
50
+ await page.click('#nonexistent');
51
+ } catch (error) {
52
+ await log.error('Click failed', false); // false = no console output
53
+ throw error;
54
+ }
55
+ });
56
+ ```
57
+
58
+ **Key Points**:
59
+
60
+ - `step()` creates collapsible steps in Playwright UI
61
+ - `info()`, `success()`, `warning()` for different message types
62
+ - `debug()` for detailed data (objects/arrays)
63
+ - `error()` with optional console suppression
64
+ - All logs appear in test reports
65
+
66
+ ### Example 2: Object and Array Logging
67
+
68
+ **Context**: Log structured data for debugging without cluttering console.
69
+
70
+ **Implementation**:
71
+
72
+ ```typescript
73
+ test('object logging', async ({ apiRequest }) => {
74
+ const { body } = await apiRequest({
75
+ method: 'GET',
76
+ path: '/api/users',
77
+ });
78
+
79
+ // Log array of objects
80
+ await log.debug(body); // Formatted as JSON in report
81
+
82
+ // Log specific object
83
+ await log.info({
84
+ totalUsers: body.length,
85
+ firstUser: body[0]?.name,
86
+ timestamp: new Date().toISOString(),
87
+ });
88
+
89
+ // Complex nested structures
90
+ await log.debug({
91
+ request: {
92
+ method: 'GET',
93
+ path: '/api/users',
94
+ timestamp: Date.now(),
95
+ },
96
+ response: {
97
+ status: 200,
98
+ body: body.slice(0, 3), // First 3 items
99
+ },
100
+ });
101
+ });
102
+ ```
103
+
104
+ **Key Points**:
105
+
106
+ - Objects auto-formatted as pretty JSON
107
+ - Arrays handled gracefully
108
+ - Nested structures supported
109
+ - All visible in Playwright report attachments
110
+
111
+ ### Example 3: Test Step Organization
112
+
113
+ **Context**: Organize test execution into collapsible steps for better readability in reports.
114
+
115
+ **Implementation**:
116
+
117
+ ```typescript
118
+ test('organized with steps', async ({ page, apiRequest }) => {
119
+ await log.step('ARRANGE: Setup test data');
120
+ const { body: user } = await apiRequest({
121
+ method: 'POST',
122
+ path: '/api/users',
123
+ body: { name: 'Test User' },
124
+ });
125
+
126
+ await log.step('ACT: Perform user action');
127
+ await page.goto(`/users/${user.id}`);
128
+ await page.click('#edit');
129
+ await page.fill('#name', 'Updated Name');
130
+ await page.click('#save');
131
+
132
+ await log.step('ASSERT: Verify changes');
133
+ await expect(page.getByText('Updated Name')).toBeVisible();
134
+
135
+ // In Playwright UI, each step is collapsible
136
+ });
137
+ ```
138
+
139
+ **Key Points**:
140
+
141
+ - `log.step()` creates collapsible sections
142
+ - Organize by Arrange-Act-Assert
143
+ - Steps visible in Playwright trace viewer
144
+ - Better debugging when tests fail
145
+
146
+ ### Example 4: Conditional Logging
147
+
148
+ **Context**: Log different messages based on environment or test conditions.
149
+
150
+ **Implementation**:
151
+
152
+ ```typescript
153
+ test('conditional logging', async ({ page }) => {
154
+ const isCI = process.env.CI === 'true';
155
+
156
+ if (isCI) {
157
+ await log.info('Running in CI environment');
158
+ } else {
159
+ await log.debug('Running locally');
160
+ }
161
+
162
+ const isKafkaWorking = await checkKafkaHealth();
163
+
164
+ if (!isKafkaWorking) {
165
+ await log.warning('Kafka unavailable - skipping event checks');
166
+ } else {
167
+ await log.step('Verifying Kafka events');
168
+ // ... event verification
169
+ }
170
+ });
171
+ ```
172
+
173
+ **Key Points**:
174
+
175
+ - Log based on environment
176
+ - Skip logging with conditionals
177
+ - Use appropriate log levels
178
+ - Debug info for local, minimal for CI
179
+
180
+ ### Example 5: Integration with Auth and API
181
+
182
+ **Context**: Log authenticated API requests with tokens (safely).
183
+
184
+ **Implementation**:
185
+
186
+ ```typescript
187
+ import { test } from '@seontechnologies/playwright-utils/fixtures';
188
+
189
+ // Helper to create safe token preview
190
+ function createTokenPreview(token: string): string {
191
+ if (!token || token.length < 10) return '[invalid]';
192
+ return `${token.slice(0, 6)}...${token.slice(-4)}`;
193
+ }
194
+
195
+ test('should log auth flow', async ({ authToken, apiRequest }) => {
196
+ await log.info(`Using token: ${createTokenPreview(authToken)}`);
197
+
198
+ await log.step('Fetch protected resource');
199
+ const { status, body } = await apiRequest({
200
+ method: 'GET',
201
+ path: '/api/protected',
202
+ headers: { Authorization: `Bearer ${authToken}` },
203
+ });
204
+
205
+ await log.debug({
206
+ status,
207
+ bodyPreview: {
208
+ id: body.id,
209
+ recordCount: body.data?.length,
210
+ },
211
+ });
212
+
213
+ await log.success('Protected resource accessed successfully');
214
+ });
215
+ ```
216
+
217
+ **Key Points**:
218
+
219
+ - Never log full tokens (security risk)
220
+ - Use preview functions for sensitive data
221
+ - Combine with auth and API utilities
222
+ - Log at appropriate detail level
223
+
224
+ ## Log Levels Guide
225
+
226
+ | Level | When to Use | Shows in Report | Shows in Console |
227
+ | --------- | ----------------------------------- | -------------------- | ---------------- |
228
+ | `step` | Test organization, major actions | ✅ Collapsible steps | ✅ Yes |
229
+ | `info` | General information, state changes | ✅ Yes | ✅ Yes |
230
+ | `success` | Successful operations | ✅ Yes | ✅ Yes |
231
+ | `warning` | Non-critical issues, skipped checks | ✅ Yes | ✅ Yes |
232
+ | `error` | Failures, exceptions | ✅ Yes | ✅ Configurable |
233
+ | `debug` | Detailed data, objects | ✅ Yes (attached) | ✅ Configurable |
234
+
235
+ ## Comparison with console.log
236
+
237
+ | console.log | log Utility |
238
+ | ----------------------- | ------------------------- |
239
+ | Not in reports | Appears in reports |
240
+ | No test steps | Creates collapsible steps |
241
+ | Manual JSON.stringify() | Auto-formats objects |
242
+ | No log levels | 6 log levels |
243
+ | Lost in CI output | Preserved in artifacts |
244
+
245
+ ## Related Fragments
246
+
247
+ - `overview.md` - Basic usage and imports
248
+ - `api-request.md` - Log API requests
249
+ - `auth-session.md` - Log auth flow (safely)
250
+ - `recurse.md` - Log polling progress
251
+
252
+ ## Anti-Patterns
253
+
254
+ **❌ Logging objects in steps:**
255
+
256
+ ```typescript
257
+ await log.step({ user: 'test', action: 'create' }); // Shows empty in UI
258
+ ```
259
+
260
+ **✅ Use strings for steps, objects for debug:**
261
+
262
+ ```typescript
263
+ await log.step('Creating user: test'); // Readable in UI
264
+ await log.debug({ user: 'test', action: 'create' }); // Detailed data
265
+ ```
266
+
267
+ **❌ Logging sensitive data:**
268
+
269
+ ```typescript
270
+ await log.info(`Password: ${password}`); // Security risk!
271
+ await log.info(`Token: ${authToken}`); // Full token exposed!
272
+ ```
273
+
274
+ **✅ Use previews or omit sensitive data:**
275
+
276
+ ```typescript
277
+ await log.info('User authenticated successfully'); // No sensitive data
278
+ await log.debug({ tokenPreview: token.slice(0, 6) + '...' });
279
+ ```
280
+
281
+ **❌ Excessive logging in loops:**
282
+
283
+ ```typescript
284
+ for (const item of items) {
285
+ await log.info(`Processing ${item.id}`); // 100 log entries!
286
+ }
287
+ ```
288
+
289
+ **✅ Log summary or use debug level:**
290
+
291
+ ```typescript
292
+ await log.step(`Processing ${items.length} items`);
293
+ await log.debug({ itemIds: items.map((i) => i.id) }); // One log entry
294
+ ```