Author orch Markdown test plan
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# Orch `run init` Test Plan Index
|
||||
|
||||
## Status
|
||||
## Case Files
|
||||
|
||||
No command case files are authored yet.
|
||||
|
||||
Use [../ROADMAP.md](../ROADMAP.md) for planned case slugs and document progress.
|
||||
| Case Slug | File | Coverage Note |
|
||||
| --- | --- | --- |
|
||||
| `run-init-creates-new-run` | [run-init-creates-new-run.md](./run-init-creates-new-run.md) | creates a new active run and persists goal and summary |
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
# Case: `run-init-creates-new-run`
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证 `run init` 会创建新的 orchestration run,并返回稳定的 run 元数据。
|
||||
|
||||
## 前置条件
|
||||
|
||||
- `TMPDIR/coord.db` 尚不存在或为空路径
|
||||
|
||||
## 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP" --summary "Public blog plus admin CRUD"
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
- 命令退出码为 `0`
|
||||
- `data.run.run_id == "run_blog_001"`
|
||||
- `data.run.goal == "Build blog MVP"`
|
||||
- `data.run.summary == "Public blog plus admin CRUD"`
|
||||
- `data.run.status == "active"`
|
||||
- 返回 `created_at` 与 `updated_at`
|
||||
|
||||
## 断言结论
|
||||
|
||||
- `run init` 会创建 run 记录,而不是只做内存态初始化
|
||||
- 新建 run 的默认状态是 `active`
|
||||
|
||||
## 补充约束
|
||||
|
||||
- `--run` 与 `--goal` 是必填;缺失任一项都应返回 `invalid_input`
|
||||
- 当同一 `run_id` 已存在时,应返回 `invalid_state`,而不是覆盖旧 run
|
||||
Reference in New Issue
Block a user