docs: update dev status — round 29, P13.3 propose tests (19 tests, 70 total)
This commit is contained in:
@@ -970,6 +970,40 @@
|
||||
- P13.3 Propose 后端测试(accept/reject/reopen + feat_task_id 生成 + propose_code 递增)
|
||||
- 或 P14 收尾验收(如果认为核心测试覆盖已足够)
|
||||
|
||||
### 2026-03-18 05:00 UTC(第 29 轮:P13.3 Propose 后端测试 — 19 个测试)
|
||||
|
||||
本轮做了什么:
|
||||
- 编写 `tests/test_propose.py`,覆盖 Propose 后端的完整功能测试(P13.3)
|
||||
- **TestProposeCRUD**(4 个):create / list / get / update,验证 propose_code 自动生成、status 默认 open、feat_task_id 默认 None
|
||||
- **TestProposeCode**(1 个):两个 project 下分别创建 propose,验证 code 按 project 独立递增且前缀正确
|
||||
- **TestAccept**(5 个):
|
||||
- 成功 accept → 生成 story/feature task(title/description 继承、status=pending、milestone 关联)
|
||||
- 非 open milestone 拒绝
|
||||
- 已 accepted 的 propose 再次 accept 拒绝
|
||||
- feat_task_id 自动填充 + 持久化验证
|
||||
- dev 角色无 propose.accept 权限被 403 拒绝
|
||||
- **TestReject**(3 个):成功 reject / 非 open 拒绝 / dev 无权限 403
|
||||
- **TestReopen**(3 个):成功 reopen / 非 rejected 拒绝 / dev 无权限 403
|
||||
- **TestFeatTaskIdProtection**(1 个):PATCH 传入 feat_task_id 被服务端忽略
|
||||
- **TestEditRestrictions**(2 个):accepted 和 rejected 状态的 propose 编辑被 400 拒绝
|
||||
|
||||
改了哪些关键文件:
|
||||
- `HarborForge.Backend/tests/test_propose.py` — 新增(~560 行)
|
||||
|
||||
验证结果:
|
||||
- `python3 -m pytest tests/ -v` — **70 passed**(17 milestone + 34 task + 19 propose),0 failed
|
||||
- 已 commit:backend `e938507`
|
||||
|
||||
当前阻塞/风险:
|
||||
- P13.4 前端/E2E 测试尚未编写(需要运行环境)
|
||||
- P14 收尾验收未开始(手工走流程 + 数据迁移验证)
|
||||
- 无本地 MySQL/运行环境做集成验证
|
||||
|
||||
下一轮最建议继续做什么:
|
||||
- P14 收尾阶段:核心后端测试已全部通过(70 个),可以开始 P14.3 最终文档整理(更新 ZHI_TASKS.md 勾选已完成项)
|
||||
- 或回顾所有 P0-P13 任务项,标记完成状态,识别剩余未做项
|
||||
- 或补充 batch transition 前端适配确认
|
||||
|
||||
---
|
||||
|
||||
## 1. 背景
|
||||
|
||||
Reference in New Issue
Block a user