Require Cursor for every implementation unit

Why: Ensure implementation authorship is delegated per unit while the primary model remains responsible for planning and delivery management.

Evidence: The focused task-card generation regression went red then green, and git diff --check passed.

Impact: Every repository-writing implementation unit gets a fresh Cursor CLI run; unavailable or failed Cursor work is recorded as a blocker instead of being silently implemented by the primary model.

Refs: .task/feature-goal-first-delivery.md
This commit is contained in:
2026-10-14 17:10:20 +00:00
parent 90265ac670
commit d79d6c17e9
7 changed files with 61 additions and 4 deletions
+13
View File
@@ -706,9 +706,22 @@ class TaskLifecycleTests(unittest.TestCase):
card = (wt / ".task/feature-new.md").read_text()
self.assertIn("make precheck", card)
self.assertIn("交付模式:goal-first(目标、范围和交付终点一次确认;范围内连续推进)", card)
self.assertIn(
"实施执行:cursor-per-unit(每个产生仓库变更的实施单元启动一次新的 Cursor CLI 进程;"
"不得跨单元复用;主模型不直接撰写实施变更)",
card,
)
self.assertIn("人工决策点:仅限目标/范围/验收变更、重大取舍、高后果操作或无法自动判定的业务验收", card)
self.assertNotIn("authorized-continuous", card)
self.assertIn("流程依据:仓库根目录 policy/delivery.md", card)
self.assertIn("## Cursor 实施收据\n", card)
cursor_receipts = card.split("## Cursor 实施收据\n", 1)[1].split("\n## ", 1)[0]
self.assertIn(
"| 单元 ID | 预期范围 | Cursor 运行 | 结果 | 阻塞原因 | 收据路径 |",
cursor_receipts,
)
self.assertIn("| 待定义 | — | NOT_RUN | — | — | — |", cursor_receipts)
self.assertIn("一单元一新进程;Cursor 不可用或失败时记录 blocker,不得交回主模型代写", cursor_receipts)
for field in ("当前阶段", "当前增量", "方案引用", "实施计划引用", "测试计划引用"):
self.assertIn(field + ":", card)
self.assertIn("## 交付调度\n", card)