Agent skill · software engineering · sickn33
jest-skill
Generates Jest unit and integration tests in JavaScript or TypeScript. Covers mocking, snapshots, async testing, and React component testing. Use when user mentions \"Jest\", \"describe/it/expect\", \"jest.mock\", \"toMatchSnapshot\".
Why this skill is useful
Generates specific Jest testing patterns and commands that the AI wouldn't reliably generate on its own.
What it needs
About 3k tokens when loaded. Last updated 2026-08-07. 44,571 stars on the source repository.
What this skill does
Jest Testing Skill When to Use Use this skill when you need generates Jest unit and integration tests in JavaScript or TypeScript. Covers mocking, snapshots, async testing, and React component testing. Use when user mentions "Jest", "describe/it/expect", "jest.mock", "toMatchSnapshot". Triggers on: "Jest", "expect().toBe()", "jest.mock",... Core Patterns Basic Test Matchers Mocking Async Testing React Component Testing (Testing Library) Snapshot Testing Anti-Patterns Bad Good Why ----- ------ ----- expect(x === y).toBe(true) expect(x).toBe(y) Better errors No await on async Always await Swallows failures Snapshot everything Snapshot UI, assert logic Snapshot fatigue Quick Reference Task Command ------ --------- Run all npx jest Watch npx jest --watch Coverage npx jest --coverage Update snapshots npx jest --updateSnapshot Run file npx jest tests/calc.test.js Single test test.only('name', () => {}) Deep Patterns For production-grade patterns, see reference/playbook.md: Section What's Inside --------- -------------- §1 Production Config Node + React configs, path aliases, coverage thresholds §2 Mocking Deep Dive Module/partial/manual mocks, spies, timers, env vars §3 Async Patterns Promises, rejections, event emitters, streams §4 test.each Array, tagged template, describe.each for table-driven tests §5 Custom Matchers toBeWithinRange, toBeValidEmail, TypeScript declarations §6 React Testing Library userEvent, hooks, context providers §7 Snapshot Testing Component, inline, property matchers §8 API Service Testing Mocked axios, CRUD patterns, error handling §9 Global Setup Multi-project config, DB setup/teardown §10 CI/CD GitHub Actions with coverage gates §11 Debugging Table 10 common problems with fixes §12 Best Practices 15-item production checklist Limitations Use this skill only when the task clearly matches its upstream source and local project context. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills sickn33/jest-skill--078ad8