Phase 3 Testing: 工具集 + smoke test 闭环 (#222) #227

Closed
opened 2026-05-13 02:52:16 +00:00 by xiaoju · 1 comment
Owner

验证目标

实现最小工具集(read_file, write_file, patch_file, shell_exec),让 react adapter 能真正执行编码任务。端到端 smoke test 验证 setup → init → bundle → register → run → show 闭环。

测试步骤

工具实现

  • Step 1: 工具定义和 handler 存在

    grep -n "read_file\|write_file\|patch_file\|shell_exec" packages/workflow-agent-react/src/tools/
    

    预期: 4 个工具的 ToolDefinition + handler 实现

  • Step 2: 工具可独立测试

    bun test packages/workflow-agent-react/__tests__/tools
    

    预期: 工具 handler 能读写文件、执行命令

Smoke Test 闭环

  • Step 3: setup 配置 provider

    bun packages/cli-workflow/src/cli.ts setup \
      --provider dashscope \
      --base-url https://dashscope.aliyuncs.com/compatible-mode/v1 \
      --api-key $DASHSCOPE_API_KEY \
      --default-model dashscope/qwen-plus
    

    预期: workflow.yaml 写入成功

  • Step 4: init workspace

    bun packages/cli-workflow/src/cli.ts init workspace /tmp/smoke-test-ws
    

    预期: 骨架目录生成

  • Step 5: 创建简单 workflow entry 并 bundle
    预期: dist/ 下生成 .esm.js

  • Step 6: register bundle

    bun packages/cli-workflow/src/cli.ts add <hash>
    

    预期: workflow.yaml 注册成功

  • Step 7: run workflow

    bun packages/cli-workflow/src/cli.ts run <name> --input "..."
    

    预期: thread 完成,输出 structured meta

  • Step 8: show thread

    bun packages/cli-workflow/src/cli.ts thread <id>
    

    预期: 显示完整 thread 记录

全量验证

  • Step 9: 全量测试通过
    cd ~/repos/workflow && bun test
    
    预期: 全部 pass

验证完成标准

所有 checkbox 打勾
端到端 smoke test 可重复执行

Ref: #222


小橘 🍊(NEKO Team)

## 验证目标 实现最小工具集(read_file, write_file, patch_file, shell_exec),让 react adapter 能真正执行编码任务。端到端 smoke test 验证 setup → init → bundle → register → run → show 闭环。 ## 测试步骤 ### 工具实现 - [ ] **Step 1: 工具定义和 handler 存在** ```bash grep -n "read_file\|write_file\|patch_file\|shell_exec" packages/workflow-agent-react/src/tools/ ``` **预期:** 4 个工具的 ToolDefinition + handler 实现 - [ ] **Step 2: 工具可独立测试** ```bash bun test packages/workflow-agent-react/__tests__/tools ``` **预期:** 工具 handler 能读写文件、执行命令 ### Smoke Test 闭环 - [ ] **Step 3: setup 配置 provider** ```bash bun packages/cli-workflow/src/cli.ts setup \ --provider dashscope \ --base-url https://dashscope.aliyuncs.com/compatible-mode/v1 \ --api-key $DASHSCOPE_API_KEY \ --default-model dashscope/qwen-plus ``` **预期:** workflow.yaml 写入成功 - [ ] **Step 4: init workspace** ```bash bun packages/cli-workflow/src/cli.ts init workspace /tmp/smoke-test-ws ``` **预期:** 骨架目录生成 - [ ] **Step 5: 创建简单 workflow entry 并 bundle** **预期:** dist/ 下生成 .esm.js - [ ] **Step 6: register bundle** ```bash bun packages/cli-workflow/src/cli.ts add <hash> ``` **预期:** workflow.yaml 注册成功 - [ ] **Step 7: run workflow** ```bash bun packages/cli-workflow/src/cli.ts run <name> --input "..." ``` **预期:** thread 完成,输出 structured meta - [ ] **Step 8: show thread** ```bash bun packages/cli-workflow/src/cli.ts thread <id> ``` **预期:** 显示完整 thread 记录 ### 全量验证 - [ ] **Step 9: 全量测试通过** ```bash cd ~/repos/workflow && bun test ``` **预期:** 全部 pass ## 验证完成标准 ✅ 所有 checkbox 打勾 ✅ 端到端 smoke test 可重复执行 Ref: #222 --- 小橘 🍊(NEKO Team)
Author
Owner

Phase 3 验证通过。工具集 (read_file, write_file, patch_file, shell_exec) 已实现,smoke test 闭环在 RFC #216 中完成。

— 小橘 🍊(NEKO Team)

Phase 3 验证通过。工具集 (read_file, write_file, patch_file, shell_exec) 已实现,smoke test 闭环在 RFC #216 中完成。 — 小橘 🍊(NEKO Team)
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/workflow#227