用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/Objective-Arts/lens-dist --skill testing命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | testing |
| description | Write and run tests. Tests are REQUIRED. All must pass. |
Write and RUN tests. Tests are REQUIRED, not optional.
No arguments? Describe this skill and stop. Do not execute.
mkdir -p .claude && echo '{"skill":"test","started":"'$(date -Iseconds)'"}' > .claude/active-workflow.json
Write tests a master craftsperson would be proud of.
Tests must look like they were written by a skilled human engineer, not generated by AI.
Test: Would you trust this test suite to catch real bugs? If not, improve it.
You MUST write and run tests. Not "consider testing" - WRITE TESTS.
For each category that applies to the target code, write at least one test:
Skip categories that genuinely don't apply (e.g., no file I/O means no corrupted data test). But document which categories you skipped and why.
/testing unit - Unit tests only/testing integration - Integration tests only/testing e2e - E2E tests only/testing all or /testing - All appropriate levelsBefore starting, read these canon skills and apply their principles throughout:
Always load:
canon/testing/test-doubles/SKILL.mdcanon/testing/test-strategy/SKILL.mdAuto-detect domain canon (check files, load matches):
| Check | If found, also read |
|---|---|
*.ts or *.js files in target | canon/javascript/typescript/SUMMARY.md, canon/javascript/js-safety/SUMMARY.md, canon/javascript/js-perf/SUMMARY.md, canon/javascript/js-internals/SUMMARY.md, canon/javascript/functional/SUMMARY.md |
angular.json in project root | canon/angular/angular-arch/SUMMARY.md, canon/angular/angular-core/SUMMARY.md, canon/angular/angular-perf/SUMMARY.md, canon/angular/rxjs/SUMMARY.md |
package.json contains "react" | canon/javascript/react-state/SUMMARY.md, canon/javascript/react-test/SUMMARY.md, canon/javascript/reactivity/SUMMARY.md |
pom.xml or build.gradle in project | canon/java/SUMMARY.md |
*.py files in target | canon/python/python-advanced/SUMMARY.md, canon/python/python-idioms/SUMMARY.md, canon/python/python-patterns/SUMMARY.md, canon/python/python-protocols/SUMMARY.md |
*.cs files or *.csproj in project | canon/csharp/csharp-depth/SUMMARY.md, canon/csharp/type-systems/SUMMARY.md, canon/csharp/async/SUMMARY.md |
.tsx, .jsx, or HTML template files | canon/ui-ux/components/SUMMARY.md, canon/ui-ux/usability/SUMMARY.md, canon/ui-ux/tokens/SUMMARY.md |
| Auth, tokens, secrets, encryption | canon/security/security-mindset/SUMMARY.md, canon/security/owasp/SUMMARY.md, canon/security/web-security/SUMMARY.md |
If a skill file doesn't exist (not installed in this project), skip it and continue. List loaded experts in EXPERTS_LOADED. In EXPERT_DECISIONS, show each specific test decision an expert drove.
keychain.ts → mock crypto.ts (dependency) ✓, mock storage.ts I/O (dependency) ✓, mock keychain.ts itself ✗## Tests: [target]
TESTS_WRITTEN:
- src/__tests__/user.test.ts: [test descriptions]
- src/__tests__/auth.test.ts: [test descriptions]
TESTS_RUN: yes (MANDATORY)
TESTS_PASSED: N
TESTS_FAILED: 0 (must be zero)
TEST_COUNT: N
MOCK_AUDIT:
- [module under test]: mocks [dependency] ✓ | mocks self ✗ (FIXED)
- [module under test]: no mocks, tests real implementation ✓
COVERAGE:
- createUser: tested (happy path, validation error, duplicate email)
- validateToken: tested (valid, expired, malformed)
EXPERTS_LOADED: [list of skill names actually read]
EXPERT_DECISIONS:
- [expert-skill]: [specific test decision it drove]
TESTING_COMPLETE
After testing:
Your turn ends here. Output TESTING_COMPLETE and STOP.