Add E2E tests for MCP Tool Execution and Session Lifecycle

- Implement comprehensive end-to-end tests for MCP Tool Execution, covering tool discovery, execution, parameter validation, error handling, and timeout scenarios.
- Introduce tests for the complete lifecycle of a workflow session, including initialization, task management, status updates, and archiving.
- Validate dual parameter format support and handle boundary conditions such as invalid JSON, non-existent sessions, and path traversal attempts.
- Ensure concurrent task updates are handled without data loss and that task data is preserved when archiving sessions.
- List sessions across all locations and verify metadata inclusion in the results.
This commit is contained in:
catlog22
2026-01-05 09:44:08 +08:00
parent 33f2aef4e6
commit b361f42c1c
7 changed files with 2541 additions and 0 deletions

View File

@@ -13,6 +13,7 @@
"start": "node ccw/bin/ccw.js",
"test": "node --experimental-strip-types --test ccw/tests/*.test.js",
"test:visual": "node --experimental-strip-types --test ccw/tests/visual/**/*.visual.test.ts",
"test:e2e": "node --experimental-strip-types --test ccw/tests/e2e/*.e2e.test.ts",
"prepublishOnly": "npm run build && echo 'Ready to publish @dyw/claude-code-workflow'"
},
"keywords": [