@guanlin4924/devflow-pi 0.1.93 → 0.1.95

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 (369) hide show
  1. package/README.md +10 -10
  2. package/node_modules/@playwright/test/LICENSE +202 -0
  3. package/node_modules/@playwright/test/NOTICE +5 -0
  4. package/node_modules/@playwright/test/README.md +318 -0
  5. package/node_modules/@playwright/test/cli.js +19 -0
  6. package/node_modules/@playwright/test/index.d.ts +18 -0
  7. package/node_modules/@playwright/test/index.js +17 -0
  8. package/node_modules/@playwright/test/index.mjs +18 -0
  9. package/node_modules/@playwright/test/package.json +35 -0
  10. package/node_modules/@playwright/test/reporter.d.ts +17 -0
  11. package/node_modules/@playwright/test/reporter.js +17 -0
  12. package/node_modules/@playwright/test/reporter.mjs +17 -0
  13. package/node_modules/playwright/LICENSE +202 -0
  14. package/node_modules/playwright/NOTICE +5 -0
  15. package/node_modules/playwright/README.md +318 -0
  16. package/node_modules/playwright/ThirdPartyNotices.txt +14 -0
  17. package/node_modules/playwright/cli.js +19 -0
  18. package/node_modules/playwright/index.d.ts +17 -0
  19. package/node_modules/playwright/index.js +17 -0
  20. package/node_modules/playwright/index.mjs +18 -0
  21. package/node_modules/playwright/jsx-runtime.js +42 -0
  22. package/node_modules/playwright/jsx-runtime.mjs +21 -0
  23. package/node_modules/playwright/lib/agents/agentParser.js +89 -0
  24. package/node_modules/playwright/lib/agents/copilot-setup-steps.yml +34 -0
  25. package/node_modules/playwright/lib/agents/generateAgents.js +395 -0
  26. package/node_modules/playwright/lib/agents/playwright-test-coverage.prompt.md +31 -0
  27. package/node_modules/playwright/lib/agents/playwright-test-generate.prompt.md +8 -0
  28. package/node_modules/playwright/lib/agents/playwright-test-generator.agent.md +88 -0
  29. package/node_modules/playwright/lib/agents/playwright-test-heal.prompt.md +6 -0
  30. package/node_modules/playwright/lib/agents/playwright-test-healer.agent.md +56 -0
  31. package/node_modules/playwright/lib/agents/playwright-test-plan.prompt.md +9 -0
  32. package/node_modules/playwright/lib/agents/playwright-test-planner.agent.md +74 -0
  33. package/node_modules/playwright/lib/cli/reportActions.js +78 -0
  34. package/node_modules/playwright/lib/cli/testActions.js +214 -0
  35. package/node_modules/playwright/lib/common/index.js +2923 -0
  36. package/node_modules/playwright/lib/common/index.js.txt +34 -0
  37. package/node_modules/playwright/lib/errorContext.js +129 -0
  38. package/node_modules/playwright/lib/globals.js +58 -0
  39. package/node_modules/playwright/lib/index.js +815 -0
  40. package/node_modules/playwright/lib/isomorphic.js +260 -0
  41. package/node_modules/playwright/lib/isomorphic.js.txt +9 -0
  42. package/node_modules/playwright/lib/loader/loaderProcessEntry.js +34 -0
  43. package/node_modules/playwright/lib/loader/loaderProcessEntry.js.txt +9 -0
  44. package/node_modules/playwright/lib/matchers/expect.js +13490 -0
  45. package/node_modules/playwright/lib/matchers/expect.js.LICENSE +640 -0
  46. package/node_modules/playwright/lib/matchers/expect.js.txt +67 -0
  47. package/node_modules/playwright/lib/mcp/test/browserBackend.js +135 -0
  48. package/node_modules/playwright/lib/mcp/test/generatorTools.js +122 -0
  49. package/node_modules/playwright/lib/mcp/test/plannerTools.js +150 -0
  50. package/node_modules/playwright/lib/mcp/test/seed.js +82 -0
  51. package/node_modules/playwright/lib/mcp/test/streams.js +44 -0
  52. package/node_modules/playwright/lib/mcp/test/testBackend.js +99 -0
  53. package/node_modules/playwright/lib/mcp/test/testContext.js +306 -0
  54. package/node_modules/playwright/lib/mcp/test/testTool.js +30 -0
  55. package/node_modules/playwright/lib/mcp/test/testTools.js +98 -0
  56. package/node_modules/playwright/lib/package.js +47 -0
  57. package/node_modules/playwright/lib/program.js +241 -0
  58. package/node_modules/playwright/lib/runner/index.js +8527 -0
  59. package/node_modules/playwright/lib/runner/index.js.txt +61 -0
  60. package/node_modules/playwright/lib/transform/babelBundle.js +72274 -0
  61. package/node_modules/playwright/lib/transform/babelBundle.js.LICENSE +2384 -0
  62. package/node_modules/playwright/lib/transform/babelBundle.js.txt +325 -0
  63. package/node_modules/playwright/lib/transform/esmLoader.js +8054 -0
  64. package/node_modules/playwright/lib/transform/esmLoader.js.LICENSE +355 -0
  65. package/node_modules/playwright/lib/transform/esmLoader.js.txt +60 -0
  66. package/node_modules/playwright/lib/util.js +373 -0
  67. package/node_modules/playwright/lib/worker/workerProcessEntry.js +1861 -0
  68. package/node_modules/playwright/lib/worker/workerProcessEntry.js.txt +19 -0
  69. package/node_modules/playwright/package.json +55 -0
  70. package/node_modules/playwright/test.d.ts +18 -0
  71. package/node_modules/playwright/test.js +24 -0
  72. package/node_modules/playwright/test.mjs +35 -0
  73. package/node_modules/playwright/types/test.d.ts +11074 -0
  74. package/node_modules/playwright/types/testReporter.d.ts +950 -0
  75. package/node_modules/playwright-core/LICENSE +202 -0
  76. package/node_modules/playwright-core/NOTICE +5 -0
  77. package/node_modules/playwright-core/README.md +3 -0
  78. package/node_modules/playwright-core/ThirdPartyNotices.txt +13 -0
  79. package/node_modules/playwright-core/bin/install_media_pack.ps1 +5 -0
  80. package/node_modules/playwright-core/bin/install_webkit_wsl.ps1 +33 -0
  81. package/node_modules/playwright-core/bin/reinstall_chrome_beta_linux.sh +42 -0
  82. package/node_modules/playwright-core/bin/reinstall_chrome_beta_mac.sh +13 -0
  83. package/node_modules/playwright-core/bin/reinstall_chrome_beta_win.ps1 +24 -0
  84. package/node_modules/playwright-core/bin/reinstall_chrome_stable_linux.sh +42 -0
  85. package/node_modules/playwright-core/bin/reinstall_chrome_stable_mac.sh +12 -0
  86. package/node_modules/playwright-core/bin/reinstall_chrome_stable_win.ps1 +24 -0
  87. package/node_modules/playwright-core/bin/reinstall_msedge_beta_linux.sh +48 -0
  88. package/node_modules/playwright-core/bin/reinstall_msedge_beta_mac.sh +11 -0
  89. package/node_modules/playwright-core/bin/reinstall_msedge_beta_win.ps1 +23 -0
  90. package/node_modules/playwright-core/bin/reinstall_msedge_dev_linux.sh +48 -0
  91. package/node_modules/playwright-core/bin/reinstall_msedge_dev_mac.sh +11 -0
  92. package/node_modules/playwright-core/bin/reinstall_msedge_dev_win.ps1 +23 -0
  93. package/node_modules/playwright-core/bin/reinstall_msedge_stable_linux.sh +48 -0
  94. package/node_modules/playwright-core/bin/reinstall_msedge_stable_mac.sh +11 -0
  95. package/node_modules/playwright-core/bin/reinstall_msedge_stable_win.ps1 +24 -0
  96. package/node_modules/playwright-core/browsers.json +52 -0
  97. package/node_modules/playwright-core/cli.js +21 -0
  98. package/node_modules/playwright-core/index.d.ts +17 -0
  99. package/node_modules/playwright-core/index.js +17 -0
  100. package/node_modules/playwright-core/index.mjs +28 -0
  101. package/node_modules/playwright-core/lib/bootstrap.js +88 -0
  102. package/node_modules/playwright-core/lib/coreBundle.js +75813 -0
  103. package/node_modules/playwright-core/lib/entry/cliDaemon.js +5 -0
  104. package/node_modules/playwright-core/lib/entry/dashboardApp.js +3 -0
  105. package/node_modules/playwright-core/lib/entry/mcp.js +10 -0
  106. package/node_modules/playwright-core/lib/entry/oopBrowserDownload.js +3 -0
  107. package/node_modules/playwright-core/lib/package.js +50 -0
  108. package/node_modules/playwright-core/lib/server/chromium/appIcon.png +0 -0
  109. package/node_modules/playwright-core/lib/server/electron/loader.js +116 -0
  110. package/node_modules/playwright-core/lib/serverRegistry.js +1939 -0
  111. package/node_modules/playwright-core/lib/serverRegistry.js.LICENSE +65 -0
  112. package/node_modules/playwright-core/lib/tools/cli-client/channelSessions.js +141 -0
  113. package/node_modules/playwright-core/lib/tools/cli-client/cli.js +6 -0
  114. package/node_modules/playwright-core/lib/tools/cli-client/help.json +721 -0
  115. package/node_modules/playwright-core/lib/tools/cli-client/minimist.js +128 -0
  116. package/node_modules/playwright-core/lib/tools/cli-client/output.js +351 -0
  117. package/node_modules/playwright-core/lib/tools/cli-client/program.js +418 -0
  118. package/node_modules/playwright-core/lib/tools/cli-client/registry.js +180 -0
  119. package/node_modules/playwright-core/lib/tools/cli-client/session.js +259 -0
  120. package/node_modules/playwright-core/lib/tools/dashboard/appIcon.png +0 -0
  121. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/SKILL.md +425 -0
  122. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/element-attributes.md +23 -0
  123. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/playwright-tests.md +39 -0
  124. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/request-mocking.md +87 -0
  125. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/running-code.md +241 -0
  126. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/session-management.md +225 -0
  127. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/storage-state.md +275 -0
  128. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/test-generation.md +433 -0
  129. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/tracing.md +139 -0
  130. package/node_modules/playwright-core/lib/tools/skills/playwright-cli/references/video-recording.md +143 -0
  131. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/SKILL.md +136 -0
  132. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/references/gallery-spec.md +144 -0
  133. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/references/migration.md +89 -0
  134. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/references/react.md +69 -0
  135. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/references/typing.md +173 -0
  136. package/node_modules/playwright-core/lib/tools/skills/playwright-component-testing/references/vue.md +77 -0
  137. package/node_modules/playwright-core/lib/tools/skills/playwright-trace/SKILL.md +174 -0
  138. package/node_modules/playwright-core/lib/tools/utils/extension.js +112 -0
  139. package/node_modules/playwright-core/lib/tools/utils/socketConnection.js +108 -0
  140. package/node_modules/playwright-core/lib/utilsBundle.js +85357 -0
  141. package/node_modules/playwright-core/lib/utilsBundle.js.LICENSE +1890 -0
  142. package/node_modules/playwright-core/lib/vite/dashboard/assets/codeMirrorModule--QdMvsKi.css +1 -0
  143. package/node_modules/playwright-core/lib/vite/dashboard/assets/codeMirrorModule-CQ8RZGBm.js +32 -0
  144. package/node_modules/playwright-core/lib/vite/dashboard/assets/codicon-DCmgc-ay.ttf +0 -0
  145. package/node_modules/playwright-core/lib/vite/dashboard/assets/firefox-1bWoP6pv.svg +1 -0
  146. package/node_modules/playwright-core/lib/vite/dashboard/assets/firefox-beta-k3eOH_eK.svg +1 -0
  147. package/node_modules/playwright-core/lib/vite/dashboard/assets/firefox-nightly-Cp5nfeDT.svg +1 -0
  148. package/node_modules/playwright-core/lib/vite/dashboard/assets/index-AwgwcYie.css +1 -0
  149. package/node_modules/playwright-core/lib/vite/dashboard/assets/index-hRvO4yU2.js +12 -0
  150. package/node_modules/playwright-core/lib/vite/dashboard/assets/safari-na3_-uQk.svg +1 -0
  151. package/node_modules/playwright-core/lib/vite/dashboard/index.html +29 -0
  152. package/node_modules/playwright-core/lib/vite/dashboard/playwright-logo.svg +24 -0
  153. package/node_modules/playwright-core/lib/vite/htmlReport/index.html +16 -0
  154. package/node_modules/playwright-core/lib/vite/htmlReport/report.css +2 -0
  155. package/node_modules/playwright-core/lib/vite/htmlReport/report.js +32 -0
  156. package/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule--QdMvsKi.css +1 -0
  157. package/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule-CVQWJZAA.js +32 -0
  158. package/node_modules/playwright-core/lib/vite/recorder/assets/codicon-DCmgc-ay.ttf +0 -0
  159. package/node_modules/playwright-core/lib/vite/recorder/assets/index-BZpYJZ-P.css +1 -0
  160. package/node_modules/playwright-core/lib/vite/recorder/assets/index-hrlLqLtq.js +129 -0
  161. package/node_modules/playwright-core/lib/vite/recorder/index.html +29 -0
  162. package/node_modules/playwright-core/lib/vite/recorder/playwright-logo.svg +9 -0
  163. package/node_modules/playwright-core/lib/vite/traceViewer/assets/codeMirrorModule-BbkfBe3n.js +32 -0
  164. package/node_modules/playwright-core/lib/vite/traceViewer/assets/defaultSettingsView-Ds6CBOo0.js +182 -0
  165. package/node_modules/playwright-core/lib/vite/traceViewer/assets/urlMatch-L3liM589.js +1 -0
  166. package/node_modules/playwright-core/lib/vite/traceViewer/assets/xtermModule-DywYcAf8.js +7 -0
  167. package/node_modules/playwright-core/lib/vite/traceViewer/codeMirrorModule.-QdMvsKi.css +1 -0
  168. package/node_modules/playwright-core/lib/vite/traceViewer/codicon.DCmgc-ay.ttf +0 -0
  169. package/node_modules/playwright-core/lib/vite/traceViewer/defaultSettingsView.Bqk9acqE.css +1 -0
  170. package/node_modules/playwright-core/lib/vite/traceViewer/index.B4cLoZK3.js +1 -0
  171. package/node_modules/playwright-core/lib/vite/traceViewer/index.B_TqY17P.css +1 -0
  172. package/node_modules/playwright-core/lib/vite/traceViewer/index.html +44 -0
  173. package/node_modules/playwright-core/lib/vite/traceViewer/manifest.webmanifest +16 -0
  174. package/node_modules/playwright-core/lib/vite/traceViewer/playwright-logo.svg +9 -0
  175. package/node_modules/playwright-core/lib/vite/traceViewer/snapshot.B_Jk1wbt.js +1 -0
  176. package/node_modules/playwright-core/lib/vite/traceViewer/snapshot.html +10 -0
  177. package/node_modules/playwright-core/lib/vite/traceViewer/sw.bundle.js +4 -0
  178. package/node_modules/playwright-core/lib/vite/traceViewer/uiMode.CU5KtEkS.js +5 -0
  179. package/node_modules/playwright-core/lib/vite/traceViewer/uiMode.CyMfwkXJ.css +1 -0
  180. package/node_modules/playwright-core/lib/vite/traceViewer/uiMode.html +18 -0
  181. package/node_modules/playwright-core/lib/vite/traceViewer/xtermModule.kHJ-D0s7.css +1 -0
  182. package/node_modules/playwright-core/lib/webp_codec.LICENSE +173 -0
  183. package/node_modules/playwright-core/lib/webp_codec.wasm +0 -0
  184. package/node_modules/playwright-core/lib/xdg-open +1267 -0
  185. package/node_modules/playwright-core/package.json +34 -0
  186. package/node_modules/playwright-core/types/protocol.d.ts +24645 -0
  187. package/node_modules/playwright-core/types/structs.d.ts +52 -0
  188. package/node_modules/playwright-core/types/types.d.ts +26632 -0
  189. package/package.json +12 -2
  190. package/plugins/devflow-core/extensions/devflow-core.ts +518 -40
  191. package/plugins/devflow-core/runtime/hooks/context_sync_gate.py +3 -3
  192. package/plugins/devflow-core/runtime/hooks/hook_common.py +334 -11
  193. package/plugins/devflow-core/runtime/hooks/index_gate.py +29 -16
  194. package/plugins/devflow-core/runtime/hooks/start.py +13 -13
  195. package/plugins/devflow-core/skills/wireframe-proposal/SKILL.md +2 -2
  196. package/plugins/devflow-core/skills/wireframe-validate/SKILL.md +4 -4
  197. package/plugins/devflow-core/skills/workflow-orchestrator/SKILL.md +19 -19
  198. package/plugins/devflow-core/skills/workflow-orchestrator/agents/openai.yaml +2 -2
  199. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/acceptance_test_runner.py +412 -76
  200. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/advance_state.rb +60 -9
  201. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/api_test_matrix.py +2 -2
  202. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/approval_pins.py +433 -0
  203. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/approval_store.py +137 -0
  204. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/architecture_assessment.rb +1 -1
  205. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/architecture_brief.rb +1 -1
  206. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/architecture_feasibility.rb +1 -1
  207. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/business_invalidation.rb +5 -5
  208. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/business_model_commit.rb +4 -4
  209. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/business_model_validate.py +1 -1
  210. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/business_source_resolver.rb +4 -4
  211. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/checker_adapter.rb +7 -7
  212. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/control_io.rb +51 -7
  213. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/cross_track_consistency_check.rb +1 -1
  214. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/dsl_coverage.py +87 -0
  215. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/dsl_v1.py +318 -0
  216. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/environment_profile.py +134 -0
  217. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/execution_contract.rb +7 -6
  218. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/execution_surface.py +138 -0
  219. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/gate_runtime.rb +3 -3
  220. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/init_state.rb +5 -5
  221. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/init_workflow.rb +5 -5
  222. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/inspect_state.rb +13 -13
  223. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/machine_evidence.rb +3 -3
  224. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/manage_lessons.rb +7 -7
  225. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/parallel_recover.rb +2 -2
  226. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/parallel_run.rb +3 -3
  227. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/phase_ownership.rb +6 -6
  228. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/playwright_adapter.py +515 -0
  229. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/repair_control_plane.rb +1 -1
  230. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/requirement_coverage.rb +1 -1
  231. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/requirement_graph.rb +3 -3
  232. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/review_preflight.py +3 -3
  233. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/review_run.py +18 -18
  234. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/runtime_context_collector.rb +3 -3
  235. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/session_rollover.rb +4 -4
  236. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/static_runtime_context_collector.rb +2 -2
  237. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/sync_artifacts.rb +5 -5
  238. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/tc_hash.py +132 -0
  239. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/tdd_evidence.py +3 -3
  240. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/test_command_policy.py +104 -10
  241. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/test_task_binding_check.py +3 -3
  242. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/update_triage_route.rb +3 -3
  243. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/validate_state.rb +19 -6
  244. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/wireframe_commit.rb +5 -5
  245. package/plugins/devflow-core/skills/workflow-orchestrator/scripts/wireframe_validate.py +1 -1
  246. package/plugins/devflow-core/skills/workflow-orchestrator/templates/acceptance-remediation.yaml +12 -12
  247. package/plugins/devflow-core/skills/workflow-orchestrator/templates/feature-development.yaml +201 -222
  248. package/plugins/devflow-core/skills/workflow-pipeline/SKILL.md +6 -4
  249. package/plugins/devflow-core/skills/workflow-pipeline/references/pipeline-flow.md +68 -140
  250. package/plugins/devflow-core/skills/workflow-project-context/SKILL.md +14 -14
  251. package/plugins/devflow-core/skills/workflow-project-context/assets/agents-md-template.md +7 -7
  252. package/plugins/devflow-core/skills/workflow-project-context/assets/codebase-backend-spec-template.md +4 -4
  253. package/plugins/devflow-core/skills/workflow-project-context/assets/codebase-frontend-spec-template.md +4 -4
  254. package/plugins/devflow-core/skills/workflow-project-context/assets/codebase-navigation-template.md +1 -1
  255. package/plugins/devflow-core/skills/workflow-project-context/assets/context-domain-index-template.md +4 -4
  256. package/plugins/devflow-core/skills/workflow-project-context/assets/context-spec-index-template.md +10 -10
  257. package/plugins/devflow-core/skills/workflow-project-context/assets/execution-contract-template.md +2 -2
  258. package/plugins/devflow-core/skills/workflow-project-context/assets/navigation-index-template.md +18 -18
  259. package/plugins/devflow-core/skills/workflow-project-context/assets/project-initialization-template.md +32 -32
  260. package/plugins/devflow-core/skills/workflow-project-context/assets/rules-index-template.md +30 -30
  261. package/plugins/devflow-core/skills/workflow-project-context/assets/state-template.md +7 -7
  262. package/plugins/devflow-core/skills/workflow-project-context/references/navigation-guide.md +37 -37
  263. package/plugins/devflow-core/skills/workflow-project-context/scripts/validate_initialization.py +16 -16
  264. package/plugins/devflow-core/skills/workflow-project-context/scripts/validate_initialization_database.py +1 -1
  265. package/plugins/devflow-design/skills/workflow-api-call-guide/SKILL.md +4 -4
  266. package/plugins/devflow-design/skills/workflow-api-contract/SKILL.md +8 -8
  267. package/plugins/devflow-design/skills/workflow-api-supplement/SKILL.md +5 -5
  268. package/plugins/devflow-design/skills/workflow-architecture-feasibility/SKILL.md +1 -1
  269. package/plugins/devflow-design/skills/workflow-backend-tech-spec/SKILL.md +39 -39
  270. package/plugins/devflow-design/skills/workflow-backend-tech-spec/assets/backend-spec-template.md +10 -10
  271. package/plugins/devflow-design/skills/workflow-backend-tech-spec/references/affected-module-exploration.md +2 -2
  272. package/plugins/devflow-design/skills/workflow-backend-tech-spec/references/code-explore-guide.md +1 -1
  273. package/plugins/devflow-design/skills/workflow-backend-tech-spec/references/project-rule-contract.md +20 -20
  274. package/plugins/devflow-design/skills/workflow-design-rule-pack/SKILL.md +8 -8
  275. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/index.md +3 -3
  276. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/accessibility.md +2 -2
  277. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/component-library.md +2 -2
  278. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/design-systems.md +1 -1
  279. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/responsive-grid.md +2 -2
  280. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/stack-guidelines.md +6 -6
  281. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/recommendations/ux-patterns.md +2 -2
  282. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/tokens/project-tokens.md +1 -1
  283. package/plugins/devflow-design/skills/workflow-design-rule-pack/assets/design/tools/ui-ux-pro-max/SKILL.md +12 -12
  284. package/plugins/devflow-design/skills/workflow-design-rule-pack/scripts/install.py +2 -2
  285. package/plugins/devflow-design/skills/workflow-feature-breakdown/SKILL.md +30 -30
  286. package/plugins/devflow-design/skills/workflow-feature-breakdown/assets/output-template.md +2 -2
  287. package/plugins/devflow-design/skills/workflow-frontend-tech-spec/SKILL.md +41 -41
  288. package/plugins/devflow-design/skills/workflow-frontend-tech-spec/assets/frontend-spec-template.md +15 -15
  289. package/plugins/devflow-design/skills/workflow-frontend-tech-spec/references/affected-module-exploration.md +2 -2
  290. package/plugins/devflow-design/skills/workflow-frontend-tech-spec/references/project-rule-contract.md +25 -25
  291. package/plugins/devflow-design/skills/workflow-integration-verify/SKILL.md +13 -13
  292. package/plugins/devflow-design/skills/workflow-ui-spec/SKILL.md +23 -23
  293. package/plugins/devflow-design/skills/workflow-ui-spec/assets/ui-spec-template.md +3 -3
  294. package/plugins/devflow-implementation/agents/implementation-worker.md +2 -2
  295. package/plugins/devflow-implementation/skills/workflow-bug-fix/SKILL.md +9 -9
  296. package/plugins/devflow-implementation/skills/workflow-bug-fix/references/lesson-format.md +2 -2
  297. package/plugins/devflow-implementation/skills/workflow-bug-fix/references/root-cause-ladder.md +1 -1
  298. package/plugins/devflow-implementation/skills/workflow-change-plan/SKILL.md +17 -17
  299. package/plugins/devflow-implementation/skills/workflow-change-plan/references/code-conventions.md +1 -1
  300. package/plugins/devflow-implementation/skills/workflow-change-plan/references/output-template.md +3 -3
  301. package/plugins/devflow-implementation/skills/workflow-change-plan/references/project-rule-contract.md +16 -16
  302. package/plugins/devflow-implementation/skills/workflow-execute-phase/SKILL.md +38 -38
  303. package/plugins/devflow-implementation/skills/workflow-execute-phase/references/execute-phase.md +4 -2
  304. package/plugins/devflow-intel/agents/project-scout.md +1 -1
  305. package/plugins/devflow-intel/extensions/devflow-intel.ts +20 -19
  306. package/plugins/devflow-intel/skills/code-index-query/SKILL.md +6 -6
  307. package/plugins/devflow-intel/skills/workflow-code-index/SKILL.md +12 -12
  308. package/plugins/devflow-intel/skills/workflow-code-index/references/discovery.md +2 -2
  309. package/plugins/devflow-intel/skills/workflow-code-index/references/query-guide.md +1 -1
  310. package/plugins/devflow-intel/skills/workflow-code-index/scripts/code_index.py +31 -12
  311. package/plugins/devflow-intel/skills/workflow-code-index/scripts/core/discovery.py +2 -2
  312. package/plugins/devflow-intel/skills/workflow-code-index/scripts/core/scanner.py +4 -1
  313. package/plugins/devflow-intel/skills/workflow-code-index/scripts/validators/project_binding_check.py +4 -4
  314. package/plugins/devflow-intel/skills/workflow-context-sync/SKILL.md +14 -14
  315. package/plugins/devflow-intel/skills/workflow-context-sync/scripts/context_sync_cursor.py +2 -2
  316. package/plugins/devflow-intel/skills/workflow-update-navigation/SKILL.md +26 -26
  317. package/plugins/devflow-intel/skills/workflow-update-navigation/references/incremental-update-guide.md +2 -2
  318. package/plugins/devflow-quality/runtime/playwright/devflow-test-dsl-v1.schema.json +872 -0
  319. package/plugins/devflow-quality/runtime/playwright/playwright.config.mjs +46 -0
  320. package/plugins/devflow-quality/runtime/playwright/reporter.mjs +311 -0
  321. package/plugins/devflow-quality/runtime/playwright/runner.spec.mjs +1308 -0
  322. package/plugins/devflow-quality/runtime/playwright/runtime-manifest.json +11 -0
  323. package/plugins/devflow-quality/skills/code-review/SKILL.md +12 -12
  324. package/plugins/devflow-quality/skills/code-review/references/spec-checklist.md +1 -1
  325. package/plugins/devflow-quality/skills/workflow-acceptance-test-design/SKILL.md +11 -8
  326. package/plugins/devflow-quality/skills/workflow-gen-test-guide/SKILL.md +6 -6
  327. package/plugins/devflow-quality/skills/workflow-gen-test-guide/legacy/SKILL.md +14 -14
  328. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/SKILL.md +82 -69
  329. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/api-mainflow-rules.md +20 -15
  330. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/codebase-discovery.md +12 -10
  331. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/intermediate-format.md +115 -192
  332. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/mainflow-selection.md +27 -23
  333. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/project-dsl-contract.md +78 -153
  334. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/references/ui-mainflow-rules.md +36 -83
  335. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/scripts/compile_dsl.py +497 -556
  336. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/scripts/discover_codebases.py +2 -2
  337. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/scripts/export_legacy_testagent.py +647 -0
  338. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/scripts/normalize_case_payloads.py +10 -3
  339. package/plugins/devflow-quality/skills/workflow-generate-mainflow-cases/scripts/validate_case_payloads.py +165 -275
  340. package/plugins/devflow-quality/skills/workflow-human-acceptance/SKILL.md +61 -0
  341. package/plugins/devflow-quality/skills/workflow-release-closeout/SKILL.md +18 -18
  342. package/plugins/devflow-quality/skills/workflow-run-acceptance-tests/SKILL.md +20 -14
  343. package/plugins/devflow-requirements/skills/requirement-feasibility-review/SKILL.md +1 -1
  344. package/plugins/devflow-requirements/skills/workflow-demand-clarify/SKILL.md +10 -10
  345. package/plugins/devflow-requirements/skills/workflow-domain-modeling/SKILL.md +25 -25
  346. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/SKILL.md +49 -49
  347. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/assets/baseline-template.md +22 -22
  348. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/references/antipatterns.md +3 -3
  349. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/references/challenge-review-guide.md +3 -3
  350. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/references/project-context-guide.md +11 -11
  351. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/references/questioning.md +1 -1
  352. package/plugins/devflow-requirements/skills/workflow-requirement-baseline/references/requirement-review-checklist.md +4 -4
  353. package/plugins/devflow-requirements/skills/workflow-requirement-triage/SKILL.md +16 -16
  354. package/plugins/devflow-requirements/skills/workflow-wayfinder/SKILL.md +6 -6
  355. package/src/approval-store.ts +340 -0
  356. package/src/cli.ts +15 -0
  357. package/src/constants.ts +1 -1
  358. package/src/doctor.ts +259 -2
  359. package/src/initialization-store.ts +51 -3
  360. package/src/paths.ts +12 -1
  361. package/src/project-context.ts +60 -15
  362. package/src/project-documents.ts +61 -61
  363. package/src/project-initializer.ts +9 -8
  364. package/src/project-layout.ts +217 -0
  365. package/src/runtime.ts +3 -3
  366. package/templates/commands/start.md +4 -4
  367. package/templates/omp/AGENTS.md +1 -1
  368. package/templates/omp/hook-config.json +13 -7
  369. package/templates/omp/index-policy.json +8 -8
@@ -0,0 +1,88 @@
1
+ ---
2
+ name: playwright-test-generator
3
+ description: Use this agent when you need to create automated browser tests using Playwright
4
+ model: sonnet
5
+ color: blue
6
+ tools:
7
+ - search
8
+ - playwright-test/browser_click
9
+ - playwright-test/browser_drag
10
+ - playwright-test/browser_evaluate
11
+ - playwright-test/browser_file_upload
12
+ - playwright-test/browser_handle_dialog
13
+ - playwright-test/browser_hover
14
+ - playwright-test/browser_navigate
15
+ - playwright-test/browser_press_key
16
+ - playwright-test/browser_select_option
17
+ - playwright-test/browser_snapshot
18
+ - playwright-test/browser_type
19
+ - playwright-test/browser_verify_element_visible
20
+ - playwright-test/browser_verify_list_visible
21
+ - playwright-test/browser_verify_text_visible
22
+ - playwright-test/browser_verify_value
23
+ - playwright-test/browser_wait_for
24
+ - playwright-test/generator_read_log
25
+ - playwright-test/generator_setup_page
26
+ - playwright-test/generator_write_test
27
+ ---
28
+
29
+ You are a Playwright Test Generator, an expert in browser automation and end-to-end testing.
30
+ Your specialty is creating robust, reliable Playwright tests that accurately simulate user interactions and validate
31
+ application behavior.
32
+
33
+ # For each test you generate
34
+ - Obtain the test plan with all the steps and verification specification
35
+ - Run the `generator_setup_page` tool to set up page for the scenario
36
+ - For each step and verification in the scenario, do the following:
37
+ - Use Playwright tool to manually execute it in real-time.
38
+ - Use the step description as the intent for each Playwright tool call.
39
+ - Retrieve generator log via `generator_read_log`
40
+ - Immediately after reading the test log, invoke `generator_write_test` with the generated source code
41
+ - File should contain single test
42
+ - File name must be fs-friendly scenario name
43
+ - Test must be placed in a describe matching the top-level test plan item
44
+ - Test title must match the scenario name
45
+ - Includes a comment with the step text before each step execution. Do not duplicate comments if step requires
46
+ multiple actions.
47
+ - Always use best practices from the log when generating tests.
48
+
49
+ <example-generation>
50
+ For following plan:
51
+
52
+ ```markdown file=specs/plan.md
53
+ ### 1. Adding New Todos
54
+ **Seed:** `tests/seed.spec.ts`
55
+
56
+ #### 1.1 Add Valid Todo
57
+ **Steps:**
58
+ 1. Click in the "What needs to be done?" input field
59
+
60
+ #### 1.2 Add Multiple Todos
61
+ ...
62
+ ```
63
+
64
+ Following file is generated:
65
+
66
+ ```ts file=add-valid-todo.spec.ts
67
+ // spec: specs/plan.md
68
+ // seed: tests/seed.spec.ts
69
+
70
+ test.describe('Adding New Todos', () => {
71
+ test('Add Valid Todo', async { page } => {
72
+ // 1. Click in the "What needs to be done?" input field
73
+ await page.click(...);
74
+
75
+ ...
76
+ });
77
+ });
78
+ ```
79
+ </example-generation>
80
+
81
+ <example>
82
+ Context: User wants to generate a test for the test plan item.
83
+ <test-suite><!-- Verbatim name of the test spec group w/o ordinal like "Multiplication tests" --></test-suite>
84
+ <test-name><!-- Name of the test case without the ordinal like "should add two numbers" --></test-name>
85
+ <test-file><!-- Name of the file to save the test into, like tests/multiplication/should-add-two-numbers.spec.ts --></test-file>
86
+ <seed-file><!-- Seed file path from test plan --></seed-file>
87
+ <body><!-- Test case content including steps and expectations --></body>
88
+ </example>
@@ -0,0 +1,6 @@
1
+ ---
2
+ agent: playwright-test-healer
3
+ description: Fix tests
4
+ ---
5
+
6
+ Run all my tests and fix the failing ones.
@@ -0,0 +1,56 @@
1
+ ---
2
+ name: playwright-test-healer
3
+ description: Use this agent when you need to debug and fix failing Playwright tests
4
+ model: sonnet
5
+ color: red
6
+ tools:
7
+ - search
8
+ - edit
9
+ - playwright-test/browser_console_messages
10
+ - playwright-test/browser_evaluate
11
+ - playwright-test/browser_generate_locator
12
+ - playwright-test/browser_network_request
13
+ - playwright-test/browser_network_requests
14
+ - playwright-test/browser_snapshot
15
+ - playwright-test/test_debug
16
+ - playwright-test/test_list
17
+ - playwright-test/test_run
18
+ ---
19
+
20
+ You are the Playwright Test Healer, an expert test automation engineer specializing in debugging and
21
+ resolving Playwright test failures. Your mission is to systematically identify, diagnose, and fix
22
+ broken Playwright tests using a methodical approach.
23
+
24
+ Your workflow:
25
+ 1. **Initial Execution**: Run all tests using `test_run` tool to identify failing tests
26
+ 2. **Debug failed tests**: For each failing test run `test_debug`.
27
+ 3. **Error Investigation**: When the test pauses on errors, use available Playwright MCP tools to:
28
+ - Examine the error details
29
+ - Capture page snapshot to understand the context
30
+ - Analyze selectors, timing issues, or assertion failures
31
+ 4. **Root Cause Analysis**: Determine the underlying cause of the failure by examining:
32
+ - Element selectors that may have changed
33
+ - Timing and synchronization issues
34
+ - Data dependencies or test environment problems
35
+ - Application changes that broke test assumptions
36
+ 5. **Code Remediation**: Edit the test code to address identified issues, focusing on:
37
+ - Updating selectors to match current application state
38
+ - Fixing assertions and expected values
39
+ - Improving test reliability and maintainability
40
+ - For inherently dynamic data, utilize regular expressions to produce resilient locators
41
+ 6. **Verification**: Restart the test after each fix to validate the changes
42
+ 7. **Iteration**: Repeat the investigation and fixing process until the test passes cleanly
43
+
44
+ Key principles:
45
+ - Be systematic and thorough in your debugging approach
46
+ - Document your findings and reasoning for each fix
47
+ - Prefer robust, maintainable solutions over quick hacks
48
+ - Use Playwright best practices for reliable test automation
49
+ - If multiple errors exist, fix them one at a time and retest
50
+ - Provide clear explanations of what was broken and how you fixed it
51
+ - You will continue this process until the test runs successfully without any failures or errors.
52
+ - If the error persists and you have high level of confidence that the test is correct, mark this test as test.fixme()
53
+ so that it is skipped during the execution. Add a comment before the failing step explaining what is happening instead
54
+ of the expected behavior.
55
+ - Do not ask user questions, you are not interactive tool, do the most reasonable thing possible to pass the test.
56
+ - Never wait for networkidle or use other discouraged or deprecated apis
@@ -0,0 +1,9 @@
1
+ ---
2
+ agent: playwright-test-planner
3
+ description: Create test plan
4
+ ---
5
+
6
+ Create test plan for "add to cart" functionality of my app.
7
+
8
+ - Seed file: `${seedFile}`
9
+ - Test plan: `specs/coverage.plan.md`
@@ -0,0 +1,74 @@
1
+ ---
2
+ name: playwright-test-planner
3
+ description: Use this agent when you need to create comprehensive test plan for a web application or website
4
+ model: sonnet
5
+ color: green
6
+ tools:
7
+ - search
8
+ - playwright-test/browser_click
9
+ - playwright-test/browser_close
10
+ - playwright-test/browser_console_messages
11
+ - playwright-test/browser_drag
12
+ - playwright-test/browser_evaluate
13
+ - playwright-test/browser_file_upload
14
+ - playwright-test/browser_handle_dialog
15
+ - playwright-test/browser_hover
16
+ - playwright-test/browser_navigate
17
+ - playwright-test/browser_navigate_back
18
+ - playwright-test/browser_network_request
19
+ - playwright-test/browser_network_requests
20
+ - playwright-test/browser_press_key
21
+ - playwright-test/browser_run_code_unsafe
22
+ - playwright-test/browser_select_option
23
+ - playwright-test/browser_snapshot
24
+ - playwright-test/browser_take_screenshot
25
+ - playwright-test/browser_type
26
+ - playwright-test/browser_wait_for
27
+ - playwright-test/planner_setup_page
28
+ - playwright-test/planner_save_plan
29
+ ---
30
+
31
+ You are an expert web test planner with extensive experience in quality assurance, user experience testing, and test
32
+ scenario design. Your expertise includes functional testing, edge case identification, and comprehensive test coverage
33
+ planning.
34
+
35
+ You will:
36
+
37
+ 1. **Navigate and Explore**
38
+ - Invoke the `planner_setup_page` tool once to set up page before using any other tools
39
+ - Explore the browser snapshot
40
+ - Do not take screenshots unless absolutely necessary
41
+ - Use `browser_*` tools to navigate and discover interface
42
+ - Thoroughly explore the interface, identifying all interactive elements, forms, navigation paths, and functionality
43
+
44
+ 2. **Analyze User Flows**
45
+ - Map out the primary user journeys and identify critical paths through the application
46
+ - Consider different user types and their typical behaviors
47
+
48
+ 3. **Design Comprehensive Scenarios**
49
+
50
+ Create detailed test scenarios that cover:
51
+ - Happy path scenarios (normal user behavior)
52
+ - Edge cases and boundary conditions
53
+ - Error handling and validation
54
+
55
+ 4. **Structure Test Plans**
56
+
57
+ Each scenario must include:
58
+ - Clear, descriptive title
59
+ - Detailed step-by-step instructions
60
+ - Expected outcomes where appropriate
61
+ - Assumptions about starting state (always assume blank/fresh state)
62
+ - Success criteria and failure conditions
63
+
64
+ 5. **Create Documentation**
65
+
66
+ Submit your test plan using `planner_save_plan` tool.
67
+
68
+ **Quality Standards**:
69
+ - Write steps that are specific enough for any tester to follow
70
+ - Include negative testing scenarios
71
+ - Ensure scenarios are independent and can be run in any order
72
+
73
+ **Output Format**: Always save the complete test plan as a markdown file with clear headings, numbered steps, and
74
+ professional formatting suitable for sharing with development and QA teams.
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var reportActions_exports = {};
30
+ __export(reportActions_exports, {
31
+ mergeReports: () => mergeReports,
32
+ showReport: () => showReport
33
+ });
34
+ module.exports = __toCommonJS(reportActions_exports);
35
+ var import_fs = __toESM(require("fs"));
36
+ var import_path = __toESM(require("path"));
37
+ var import_common = require("../common");
38
+ var import_runner = require("../runner");
39
+ const { gracefullyProcessExitDoNotHang } = require("playwright-core/lib/coreBundle").utils;
40
+ async function showReport(report, host, port) {
41
+ await import_runner.html.showHTMLReport(report, host, port);
42
+ }
43
+ async function mergeReports(reportDir, opts) {
44
+ const configFile = opts.config;
45
+ const config = configFile ? await import_common.configLoader.loadConfigFromFile(configFile) : await import_common.configLoader.loadEmptyConfigForMergeReports();
46
+ const dir = import_path.default.resolve(process.cwd(), reportDir || "");
47
+ const dirStat = await import_fs.default.promises.stat(dir).catch((e) => null);
48
+ if (!dirStat)
49
+ throw new Error("Directory does not exist: " + dir);
50
+ if (!dirStat.isDirectory())
51
+ throw new Error(`"${dir}" is not a directory`);
52
+ let reporterDescriptions = resolveReporterOption(opts.reporter);
53
+ if (!reporterDescriptions && configFile)
54
+ reporterDescriptions = config.config.reporter;
55
+ if (!reporterDescriptions)
56
+ reporterDescriptions = [[import_common.config.defaultReporter]];
57
+ const rootDirOverride = configFile ? config.config.rootDir : void 0;
58
+ const result = await import_runner.merge.createMergedReport(config, dir, reporterDescriptions, rootDirOverride);
59
+ gracefullyProcessExitDoNotHang(result === "failed" ? 1 : 0);
60
+ }
61
+ function resolveReporterOption(reporter) {
62
+ if (!reporter || !reporter.length)
63
+ return void 0;
64
+ return reporter.split(",").map((r) => [resolveReporter(r)]);
65
+ }
66
+ function resolveReporter(id) {
67
+ if (import_common.builtInReporters.includes(id))
68
+ return id;
69
+ const localPath = import_path.default.resolve(process.cwd(), id);
70
+ if (import_fs.default.existsSync(localPath))
71
+ return localPath;
72
+ return require.resolve(id, { paths: [process.cwd()] });
73
+ }
74
+ // Annotate the CommonJS export names for ESM import in node:
75
+ 0 && (module.exports = {
76
+ mergeReports,
77
+ showReport
78
+ });
@@ -0,0 +1,214 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var testActions_exports = {};
30
+ __export(testActions_exports, {
31
+ clearCache: () => clearCache,
32
+ runTestServerAction: () => runTestServerAction,
33
+ runTests: () => runTests
34
+ });
35
+ module.exports = __toCommonJS(testActions_exports);
36
+ var import_fs = __toESM(require("fs"));
37
+ var import_path = __toESM(require("path"));
38
+ var import_common = require("../common");
39
+ var import_runner = require("../runner");
40
+ const { gracefullyProcessExitDoNotHang } = require("playwright-core/lib/coreBundle").utils;
41
+ const { startProfiling, stopProfiling } = require("playwright-core/lib/coreBundle").utils;
42
+ async function runTests(args, opts) {
43
+ await startProfiling();
44
+ const cliOverrides = overridesFromOptions(opts);
45
+ cliOverrides.argv = process.argv;
46
+ const config = await import_common.configLoader.loadConfigFromFile(opts.config, cliOverrides, opts.deps === false);
47
+ const options = {
48
+ locations: args.length ? args : void 0,
49
+ grep: opts.grep,
50
+ grepInvert: opts.grepInvert,
51
+ onlyChanged: opts.onlyChanged === true ? "HEAD" : opts.onlyChanged,
52
+ listMode: !!opts.list,
53
+ projectFilter: opts.project || void 0,
54
+ passWithNoTests: !!opts.passWithNoTests,
55
+ lastFailed: !!opts.lastFailed,
56
+ lastFailedFile: opts.lastFailedFile,
57
+ testList: opts.testList ? import_path.default.resolve(process.cwd(), opts.testList) : void 0,
58
+ testListInvert: opts.testListInvert ? import_path.default.resolve(process.cwd(), opts.testListInvert) : void 0,
59
+ shardWeights: resolveShardWeightsOption()
60
+ };
61
+ import_runner.projectUtils.filterProjects(config.projects, options.projectFilter);
62
+ if (opts.ui || opts.uiHost || opts.uiPort) {
63
+ if (opts.onlyChanged)
64
+ throw new Error(`--only-changed is not supported in UI mode. If you'd like that to change, see https://github.com/microsoft/playwright/issues/15075 for more details.`);
65
+ const status2 = await import_runner.testServer.runUIMode(opts.config, cliOverrides, {
66
+ host: opts.uiHost,
67
+ port: opts.uiPort ? +opts.uiPort : void 0,
68
+ args,
69
+ grep: opts.grep,
70
+ grepInvert: opts.grepInvert,
71
+ project: opts.project || void 0,
72
+ reporter: Array.isArray(opts.reporter) ? opts.reporter : opts.reporter ? [opts.reporter] : void 0
73
+ });
74
+ await stopProfiling("runner");
75
+ const exitCode2 = status2 === "interrupted" ? 130 : status2 === "passed" ? 0 : 1;
76
+ gracefullyProcessExitDoNotHang(exitCode2);
77
+ return;
78
+ }
79
+ if (process.env.PWTEST_WATCH) {
80
+ if (opts.onlyChanged)
81
+ throw new Error(`--only-changed is not supported in watch mode. If you'd like that to change, file an issue and let us know about your usecase for it.`);
82
+ const status2 = await import_runner.watchMode.runWatchModeLoop(
83
+ import_common.configLoader.resolveConfigLocation(opts.config),
84
+ {
85
+ projects: opts.project,
86
+ files: args,
87
+ grep: opts.grep
88
+ }
89
+ );
90
+ await stopProfiling("runner");
91
+ const exitCode2 = status2 === "interrupted" ? 130 : status2 === "passed" ? 0 : 1;
92
+ gracefullyProcessExitDoNotHang(exitCode2);
93
+ return;
94
+ }
95
+ const status = await import_runner.testRunner.runAllTestsWithConfig(config, options);
96
+ await stopProfiling("runner");
97
+ const exitCode = status === "interrupted" ? 130 : status === "passed" ? 0 : 1;
98
+ gracefullyProcessExitDoNotHang(exitCode);
99
+ }
100
+ async function runTestServerAction(opts) {
101
+ const host = opts.host;
102
+ const port = opts.port ? +opts.port : void 0;
103
+ const status = await import_runner.testServer.runTestServer(opts.config, {}, { host, port });
104
+ const exitCode = status === "interrupted" ? 130 : status === "passed" ? 0 : 1;
105
+ gracefullyProcessExitDoNotHang(exitCode);
106
+ }
107
+ async function clearCache(opts) {
108
+ const runner = new import_runner.testRunner.TestRunner(import_common.configLoader.resolveConfigLocation(opts.config), {});
109
+ const { status } = await runner.clearCache(import_runner.runnerReporters.createErrorCollectingReporter(import_runner.base.terminalScreen));
110
+ const exitCode = status === "interrupted" ? 130 : status === "passed" ? 0 : 1;
111
+ gracefullyProcessExitDoNotHang(exitCode);
112
+ }
113
+ function overridesFromOptions(options) {
114
+ if (options.ui) {
115
+ options.debug = void 0;
116
+ options.trace = void 0;
117
+ }
118
+ const overrides = {
119
+ debug: options.debug,
120
+ failOnFlakyTests: options.failOnFlakyTests ? true : void 0,
121
+ forbidOnly: options.forbidOnly ? true : void 0,
122
+ fullyParallel: options.fullyParallel ? true : void 0,
123
+ globalTimeout: options.globalTimeout ? parseInt(options.globalTimeout, 10) : void 0,
124
+ maxFailures: options.x ? 1 : options.maxFailures ? parseInt(options.maxFailures, 10) : void 0,
125
+ outputDir: options.output ? import_path.default.resolve(process.cwd(), options.output) : void 0,
126
+ pause: !!process.env.PWPAUSE,
127
+ quiet: options.quiet ? options.quiet : void 0,
128
+ repeatEach: options.repeatEach ? parseInt(options.repeatEach, 10) : void 0,
129
+ retries: options.retries ? parseInt(options.retries, 10) : void 0,
130
+ reporter: resolveReporterOption(options.reporter),
131
+ additionalReporters: resolveReporterOption(options.addReporter),
132
+ shard: resolveShardOption(options.shard),
133
+ timeout: options.timeout ? parseInt(options.timeout, 10) : void 0,
134
+ tsconfig: options.tsconfig ? import_path.default.resolve(process.cwd(), options.tsconfig) : void 0,
135
+ ignoreSnapshots: options.ignoreSnapshots ? !!options.ignoreSnapshots : void 0,
136
+ updateSnapshots: options.updateSnapshots,
137
+ updateSourceMethod: options.updateSourceMethod,
138
+ use: {
139
+ trace: options.trace
140
+ },
141
+ workers: options.workers
142
+ };
143
+ if (options.browser) {
144
+ const browserOpt = options.browser.toLowerCase();
145
+ if (!["all", "chromium", "firefox", "webkit"].includes(browserOpt))
146
+ throw new Error(`Unsupported browser "${options.browser}", must be one of "all", "chromium", "firefox" or "webkit"`);
147
+ const browserNames = browserOpt === "all" ? ["chromium", "firefox", "webkit"] : [browserOpt];
148
+ overrides.projects = browserNames.map((browserName) => {
149
+ return {
150
+ name: browserName,
151
+ use: { browserName }
152
+ };
153
+ });
154
+ }
155
+ if (options.headed)
156
+ overrides.use.headless = false;
157
+ if (options.debug === "inspector") {
158
+ overrides.use.headless = false;
159
+ process.env.PWDEBUG = "1";
160
+ }
161
+ if (overrides.tsconfig && !import_fs.default.existsSync(overrides.tsconfig))
162
+ throw new Error(`--tsconfig "${options.tsconfig}" does not exist`);
163
+ return overrides;
164
+ }
165
+ function resolveReporterOption(reporter) {
166
+ if (!reporter || !reporter.length)
167
+ return void 0;
168
+ return reporter.split(",").map((r) => [resolveReporter(r)]);
169
+ }
170
+ function resolveShardOption(shard) {
171
+ if (!shard)
172
+ return void 0;
173
+ const shardPair = shard.split("/");
174
+ if (shardPair.length !== 2) {
175
+ throw new Error(
176
+ `--shard "${shard}", expected format is "current/all", 1-based, for example "3/5".`
177
+ );
178
+ }
179
+ const current = parseInt(shardPair[0], 10);
180
+ const total = parseInt(shardPair[1], 10);
181
+ if (isNaN(total) || total < 1)
182
+ throw new Error(`--shard "${shard}" total must be a positive number`);
183
+ if (isNaN(current) || current < 1 || current > total) {
184
+ throw new Error(
185
+ `--shard "${shard}" current must be a positive number, not greater than shard total`
186
+ );
187
+ }
188
+ return { current, total };
189
+ }
190
+ function resolveShardWeightsOption() {
191
+ const shardWeights = process.env.PWTEST_SHARD_WEIGHTS;
192
+ if (!shardWeights)
193
+ return void 0;
194
+ return shardWeights.split(":").map((w) => {
195
+ const weight = parseInt(w, 10);
196
+ if (isNaN(weight) || weight < 0)
197
+ throw new Error(`PWTEST_SHARD_WEIGHTS="${shardWeights}" weights must be non-negative numbers`);
198
+ return weight;
199
+ });
200
+ }
201
+ function resolveReporter(id) {
202
+ if (import_common.builtInReporters.includes(id))
203
+ return id;
204
+ const localPath = import_path.default.resolve(process.cwd(), id);
205
+ if (import_fs.default.existsSync(localPath))
206
+ return localPath;
207
+ return require.resolve(id, { paths: [process.cwd()] });
208
+ }
209
+ // Annotate the CommonJS export names for ESM import in node:
210
+ 0 && (module.exports = {
211
+ clearCache,
212
+ runTestServerAction,
213
+ runTests
214
+ });