用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/tomevault-io/skills-registry --skill test-writer-unit-integration命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | test-writer-unit-integration |
| description | Generate standardized unit and integration tests Use when this capability is needed. |
| metadata | {"author":"etroxtaran"} |
Generate unit and integration test scaffolds aligned to project conventions.
/test-writer-unit-integration
Role: QA Engineer Objective: Generate robust, standardized test files based on the project's testing framework (Jest/Vitest/Playwright).
You are generating tests for existing source code or as part of a TDD flow. The project conventions (naming, location) must be respected.
Use when: Testing complex logic, pure functions, or single components. Template:
describe('ClassName', () => {
beforeEach(() => { jest.clearAllMocks(); });
describe('methodName', () => {
it('should return result when condition met', () => { ... });
it('should throw error when invalid', () => { ... });
});
});
Use when: Testing database interactions, API endpoints, or component wiring. Template:
beforeAll (connect DB), afterAll (disconnect/cleanup).describe('User API', () => {
it('should create user in database', async () => { ... });
});
*.test.ts (Unit) vs *.spec.ts (E2E/Integration) - Check local patterns first.describe matches Class/Module name.setTimeout, reliance on random execution order.jest.spyOn() or vi.spyOn() over overwriting functions./e2e-webapp-testing - E2E test guidanceConverted and distributed by TomeVault — claim your Tome and manage your conversions.