63 lines
2.3 KiB
Markdown
63 lines
2.3 KiB
Markdown
# Reasonix Browser Test: Batch A2 task473 Local Folder Restore Focus Closed
|
||
|
||
项目根目录:`/mnt/Data1T/mnote`
|
||
|
||
请先阅读并遵守:`/home/lix/.codex/skills/reasonix-browser-tester/SKILL.md`
|
||
|
||
## 角色
|
||
|
||
你是浏览器测试员,不是代码修改员。
|
||
|
||
禁止修改源码、禁止 git commit、禁止回滚文件。只允许创建测试输出目录、临时测试数据、截图和测试结果文件。
|
||
|
||
## 测试目标
|
||
|
||
验证 `task473-local-folder-trash-restore-no-refresh-focus-gap-smoke.js` 在当前最新 `mnote-web` 上已经关闭 local folder trash restore focus gap:
|
||
|
||
- restore 不触发浏览器 reload / navigation。
|
||
- restore 后文件恢复到原路径。
|
||
- 回到 filetree 后恢复行重新出现。
|
||
- 恢复行最终出现 focus 证据:`data-active="true"` 或 `data-selected="true"` 或 `data-focused="true"`。
|
||
|
||
## 前置
|
||
|
||
- 被测入口:`http://127.0.0.1:3012`
|
||
- 3012 是 Codex 为本轮验证启动的最新 mnote-web 临时进程。
|
||
- 使用真实浏览器或 Playwright。
|
||
- 使用全新的 isolated browser context / userDataDir;测试开始前清空 cookies、localStorage、sessionStorage、IndexedDB、Cache Storage。
|
||
|
||
## 操作
|
||
|
||
1. 运行:
|
||
|
||
```bash
|
||
cd /mnt/Data1T/mnote
|
||
node --check scripts/task473-local-folder-trash-restore-no-refresh-focus-gap-smoke.js
|
||
MNOTE_WEB_SMOKE_BASE_URL=http://127.0.0.1:3012 PLAYWRIGHT_CHROMIUM_EXECUTABLE_PATH=/usr/bin/google-chrome-stable node scripts/task473-local-folder-trash-restore-no-refresh-focus-gap-smoke.js
|
||
```
|
||
|
||
2. 读取 `tmp/task473-local-folder-trash-restore-no-refresh-focus-gap-smoke/result.json`。
|
||
3. 截图恢复后 filetree 状态,截图中应能看到恢复行或至少 filetree 区域。
|
||
4. 记录:
|
||
- `ok`
|
||
- `restoreNavFree.delta`
|
||
- `fileReappearsInFiletree`
|
||
- `focusAfterRestore`
|
||
- `restoreFocusDebug.focusStatusAfterFiletreeLoad`
|
||
|
||
## 输出目录
|
||
|
||
`/mnt/Data1T/mnote/tmp/reasonix-batch-a2-browser-task473-focus-closed-2026-05-21/`
|
||
|
||
必须输出:
|
||
|
||
- `result.json`
|
||
- `final.md`
|
||
- 至少 1 张截图;失败时必须截图。
|
||
|
||
## 判定
|
||
|
||
- `PASS`:语法检查和 smoke 实跑 exit 0,`result.json.ok=true`,`restoreNavFree.delta=0`,文件行恢复,且 `focusAfterRestore` 显示至少一个 active/selected/focused 证据为 true。
|
||
- `FAIL`:脚本退出非 0,或 no-refresh / 文件恢复 / focus 断言失败。
|
||
- `BLOCKED`:3012 不可达或浏览器无法启动。
|