运行项目测试
test-run
运行项目的测试——自动检测 pytest、vitest、jest、cargo、go test;可运行整个测试套件,或按名称模式匹配运行。当用户要求运行测试,且未指定测试层级、单个文件或修复周期时使用。
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 60
- Forks
- 6
01 前言 Front Matter
- args
- [test-pattern] [--coverage] [--watch]
- name
- test-run
- created
- 1765843200000
- modified
- 1788566400000
- reviewed
- 1777075200000
- description
- Run the project's tests — auto-detects pytest, vitest, jest, cargo, go test; whole suite or a name pattern. Use when asked to run the tests and no tier, single file, or fix cycle is named.
- allowed-tools
- Task, TodoWrite
- argument-hint
- [test-pattern] [--coverage] [--watch]
02 资源文件 8
- 参考文档references/completion.md5.0 KB
- 参考文档references/coordination.md3.5 KB
- 参考文档references/delegation.md11.5 KB
- 参考文档references/gates.md6.3 KB
- 参考文档references/phases.md10.1 KB
- 参考文档references/quality-modes.md4.2 KB
- 参考文档references/review.md4.6 KB
- 参考文档references/verification.md10.8 KB
03 SKILL.md 正文
When to Use This Skill
| Use this skill when... | Use test-quick instead when... |
|---|---|
| Running tests with auto-detected framework (pytest, vitest, jest, cargo, go) | You only want fast unit tests for sub-30s feedback |
| Running a specific file or pattern with full framework defaults | Iterating on a single failing spec (use test-focus) |
| Generating coverage in the standard run | Running the full pyramid before a PR (use test-full) |
| Starting a watch-mode dev loop across the project | Triaging existing test results (use test-analyze) |
Context
- Project indicators: !
find . -maxdepth 1 \( -name 'pyproject.toml' -o -name 'package.json' -o -name 'Cargo.toml' -o -name 'go.mod' \) - Test directories: !
find . -maxdepth 1 -type d \( -name 'tests' -o -name 'test' -o -name '__tests__' -o -name 'spec' \) - Package.json test script: !
find . -maxdepth 1 -name 'package.json' -exec grep -A2 '"test"' {} + - Pytest config: !
find . -maxdepth 1 -name 'pyproject.toml' -exec grep -A5 '\[tool.pytest' {} +
Parameters
$1: Optional test pattern or specific test file/directory--coverage: Enable coverage reporting--watch: Run tests in watch mode
Your task
Delegate this task to the test-runner agent.
Use the Agent tool with subagent_type: testing-plugin:test-runner to run tests with the appropriate framework. Pass all the context gathered in Context and the parsed parameters to the agent.
The test-runner agent should:
-
Detect project type and test framework:
- Python: pytest, unittest, nose
- Node.js: vitest, jest, mocha
- Rust: cargo test
- Go: go test
-
Run appropriate test command:
- Apply test pattern if provided
- Enable coverage if requested
- Enable watch mode if requested
-
Analyze results:
- Parse test output for pass/fail counts
- Identify failing tests with clear error messages
- Extract coverage metrics if available
-
Provide concise summary:
Tests: [PASS|FAIL] Passed: X | Failed: Y | Duration: Zs Failures (if any): - test_name: Brief error (file:line) Coverage: XX% (if requested) -
Suggest next actions:
- If failures: specific fix recommendations
- If coverage gaps: areas needing tests
- If slow: optimization suggestions
Provide the agent with:
- All context from Context
- The parsed parameters (pattern, --coverage, --watch)
- Any specific test configuration detected
The agent has expertise in:
- Multi-framework test execution
- Test failure analysis and debugging
- Coverage reporting and gap identification
- Tiered test execution (unit, integration, e2e)
04 同仓库更多 Skills
session-workflow-capture
Workflow-tool scripts and workflow friction from this session, filed as issues here or in the plugins repo. Use when a session ran Workflow scripts.
kitty-show-image
Show the user an image with a note on what to judge, via a file send or a labelled kitty tab. Use when the user must see an image, or icat fails with no /dev/tty.
kitty-session-persistence
Snapshot and restore kitty terminal sessions on macOS. Use when surviving WindowServer hangs without losing tabs, configuring snapshots, or restoring after a force-reboot.
kitty-remote-control
Safe kitty remote control from an agent — read panes with kitty @ ls/get-text, notify, and never mutate the live terminal unasked. Use when running inside kitty.
docs-reference-check
Dangling doc-reference gate: flag markdown naming repo paths or relative links that no longer exist. Use when docs cite moved/deleted files, or wiring a doc-drift lint.
YouTube 视频上传与编辑
youtube-upload
通过 Data API v3 将视频上传到 YouTube,并在之后编辑其标题、描述、标签或缩略图。适用于发布 YouTube 视频或修改其标题。