test: add a CDP-based pre-release UI smoke harness
The DSH sandbox blocks named pipes, so Chromium/WebView2 cannot start inside it (window renders white, msedgewebview2 exits immediately; Edge headless fails with a Mojo platform-channel access-denied fatal). UI verification therefore moves to a script the user runs from a normal desktop shell. - agent/tests/ui-smoke.ps1: launches the built exe with an isolated config and --remote-debugging-port, waits for the port, runs the driver, closes. - agent/tests/ui-smoke.mjs: connects over CDP, snapshots the page (preview content, headings, fold toggles, highlighted code, window.ipc bridge), saves a screenshot and a JSON report for the agent to read. - The driver was validated against a mock CDP server; the real end-to-end run needs a desktop shell (sandbox cannot host WebView2).
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
| `scripts/build.ps1` | 开发构建(cargo test + build --release + 校验) |
|
||||
| `scripts/publish.ps1` | 用户手动发布到 Nutstore(Medium) |
|
||||
| `tests/smoke.ps1` | cargo test + 关联检查 + 可选隔离启动 |
|
||||
| `tests/ui-smoke.ps1` + `ui-smoke.mjs` | 发布前 UI 冒烟:CDP 断言页面渲染、截图、JSON 报告(需普通桌面 PowerShell + Node 21+) |
|
||||
| `tests/fixtures/` | 手工/冒烟用 Markdown 样例 |
|
||||
| `reports/` | 验证记录(文本;截图放 `agent/tmp/`,不入库) |
|
||||
| `notes/` | 草稿 |
|
||||
|
||||
Reference in New Issue
Block a user