원클릭으로
automate-tests
Discover and execute repository test commands safely with evidence-based command selection and safety guardrails.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Discover and execute repository test commands safely with evidence-based command selection and safety guardrails.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Store, look up, or delete a personal credential (server SSH password, database password, website login, API key/token, certificate passphrase) in the macOS Keychain using a consistent <project>-<env>-<kind> naming scheme, and optionally record a pointer (never the secret itself) in the current project's Claude Code memory. Always use this skill whenever the user asks to save, store, remember, look up, rotate, or delete a password, API key, token, SSH credential, or database credential on this machine — even if they don't say "Keychain" or "security" explicitly, e.g. "save this database password so I don't lose it", "把这个数据库密码存一下", "记一条密钥", "这台服务器的密码帮我记下来", "what's the postgres password for staging again", "delete the old GitHub token from keychain". Do not use this for team-shared secret vaults, CI/CD secret injection, or anything that needs to sync across machines — those need a real secrets manager, not this skill.
Drain pending NATS messages from a producer contract via NATS MCP tools. Discovers the available NATS tool capabilities, selects exact-subject or wildcard mode from .cortex/nats.yaml, applies Tolerant Reader semantics, executes ack/nak/term decisions, and returns aggregated stats.
Audit and refactor existing SKILLs to meet spec compliance, repository asset boundaries, tool adaptation requirements, and LLM best practices.
From inside a linked worktree, deliver the current feature branch into main — merge with --no-ff, push, and optionally clean up the worktree, all without leaving CWD.
After code changes, auto-detect the project's build system and local deployment method for a given directory, then build the project and restart its locally-deployed environment (Docker Compose / systemd / process manager). Never assumes — asks only when detection is ambiguous. Caches detected commands per project in .cortex/redeploy-local.yaml; re-invocations on the same project skip re-scanning until signal files change, the cache expires (30 days), or the skill version bumps.
From the main repo on the main branch, scan all linked worktrees and local branches, let the user multi-select, then merge --no-ff + push them sequentially and clean up succeeded worktrees together.
| name | automate-tests |
| description | Discover and execute repository test commands safely with evidence-based command selection and safety guardrails. |
| description_zh | 安全发现并执行仓库测试命令;基于证据选择命令并设安全护栏。 |
| tags | ["automation","devops"] |
| version | 1.0.0 |
| license | MIT |
| recommended_scope | both |
| metadata | {"author":"ai-cortex"} |
| triggers | ["run tests","automated tests","auto test","autotest"] |
| compatibility | Requires git (optional), a shell, and the repo's language toolchain(s) (e.g., node, python, go, dotnet, java). |
| input_schema | {"type":"code-scope","description":"Repository path containing test configuration and source code","defaults":{"scope":"repo"}} |
| output_schema | {"type":"diagnostic-report","description":"Test plan summary with commands run, results, and failure diagnostics"} |
确定目标存储库期望如何执行自动化测试(命令、框架、先决条件和范围),然后使用安全第一的交互策略运行最佳匹配的测试套件。
首要目标:通过基于证据的命令选择和安全护栏生成测试执行结果。
成功标准(必须满足所有要求):
验收测试:开发人员可以在没有额外上下文的情况下按照测试计划摘要重现测试执行吗?
本技能负责:
本技能不负责:
转交点:当测试完成(通过或失败)时,移交给“自动修复”以修复故障或“审查测试”以进行质量评估。
建立范围和约束(询问是否不明确)
fast:仅进行单元测试,最少的设置。ci:尽可能接近地镜像 CI 工作流命令。full:包括集成/e2e 测试和服务依赖项。发现测试计划(基于证据)
CLAUDE.md 或 .ai-cortex/config.yaml,优先读取其中的 test_command;否则按以下来源发现。参见 docs/guides/project-config.md。README.md、CONTRIBUTING.md、TESTING.md、docs/testing*、Makefile.github/workflows/*.yml、.gitlab-ci.yml、azure-pipelines.yml、Jenkinsfilepackage.json、pyproject.toml、setup.cfg、tox.ini、go.mod、pom.xml、build.gradle*、*.csproj、Cargo.tomlnpm test、pnpm test、yarn test、pytest、tox、go test、dotnet test、mvn test、gradle test、cargo test等)选择执行计划
有护栏执行
不要做这些(其他技能可以处理它们):
review-codebase何时停止并交接:
rm -rf、git clean、docker system prune、数据库删除)?开发人员可以在没有额外上下文的情况下通过遵循测试计划摘要来重现测试执行吗?
如果否:测试计划摘要不完整。添加缺失的证据、命令或先决条件。
如果是:技能执行完成。如果需要,继续转交。
用户:“为此存储库运行测试。”
代理人:
package.json 脚本和 .github/Workflows/*。npm test (或者 pnpm test / yarn test 如果仓库对其进行了标准化)
3.询问:“安装依赖项(npm ci)并允许网络?”npm cinpm 测试用户:“在本地镜像 CI。”
代理:
.github/workflows/ci.yml 并识别单独的作业: