Files
mnote/.codex/reasonix-tasks/2026-05-21-batch-b2-worker-e-mindmap-smoke-resource-tab.md
T

59 lines
2.1 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Batch B2 Worker EMindmap ResourceTab Smoke Update
项目根目录:`/mnt/Data1T/mnote`
你不是单独在代码库里工作,可能有其他 worker 并行执行。不要回滚、覆盖或格式化与你任务无关的文件;不要提交 git。
## 背景
Batch B Worker C 运行:
- `scripts/task443-filetree-mindmap-click-active-row-smoke.js`
- `scripts/task445-filetree-mindmap-switch-no-flicker-smoke.js`
两个 smoke 均失败于历史 URL 断言:脚本等待 `/mindmap/${docId}/${mindmapId}`,但当前真实行为已经改为 `/documents/${docId}?workspaceId=...&resourceTab=resource%3Amindmap%3A...`
这是 smoke 过时,不是直接证明功能失败。
## 目标
更新 `task443` / `task445`,让它们验证当前 ResourceTab 路由:
- 点击 file tree 中的 mindmap asset 后,URL 应保持在 `/documents/${docId}`
- URL search params 中必须有 `resourceTab`
- `decodeURIComponent(resourceTab)` 后应包含 `resource:mindmap:${docId}:${mindmapId}`
- asset row 应保持 `data-selected="true"`
- 不应闪回父页面 row 选中。
## 允许修改范围
- `scripts/task443-filetree-mindmap-click-active-row-smoke.js`
- `scripts/task445-filetree-mindmap-switch-no-flicker-smoke.js`
- 可新增 `.codex/reasonix-tasks/results/batch-b2-worker-e-mindmap-smoke-resource-tab.md`
不要修改 Rust 业务代码、设计文档或其他 smoke。
## 验收命令
至少运行:
```bash
node --check scripts/task443-filetree-mindmap-click-active-row-smoke.js
node --check scripts/task445-filetree-mindmap-switch-no-flicker-smoke.js
```
如果本地 `http://127.0.0.1:3000` 可用,请实跑:
```bash
PLAYWRIGHT_CHROMIUM_EXECUTABLE_PATH=/usr/bin/google-chrome-stable node scripts/task443-filetree-mindmap-click-active-row-smoke.js
PLAYWRIGHT_CHROMIUM_EXECUTABLE_PATH=/usr/bin/google-chrome-stable node scripts/task445-filetree-mindmap-switch-no-flicker-smoke.js
```
## 输出要求
最终说明:
- 修改了哪些文件。
- 是否实跑 smokePASS/FAIL 结果和 `tmp/.../result.json` 路径。
- 如果 `task445` 仍有 400,请说明请求线索,不要掩盖。