Jest Generator
Generates Jest unit tests for JavaScript and TypeScript with mocking, async handling, and React component coverage.
- CCM score
- 52 of 100
- skills.sh installs
- 401
- GitHub stars
- 257
- last updated
- Aug 21, 2026
Own this skill? Claim it
What it does
- Covers test generation for JS/TS modules and React components, with source-to-test file naming such as
Feature.tsxtoFeature.test.tsx - Includes Jest patterns for mocks, spies, fake timers, async tests, common matchers, and Testing Library usage
- Provides a quality checklist that requires all exports to be tested, external dependencies mocked, and coverage of at least 80%
- Designed for projects using
bun testornpm testthat need missing coverage added to existing code
Install
$ npx -y skills add secondsky/claude-skills --skill jest-generator -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
Jest Generator Skill
Purpose
Generate Jest-based unit tests for JavaScript and TypeScript code, following Jest conventions and best practices with proper mocking, describe blocks, and code organization.
When to Use
- Generate Jest tests for JavaScript/TypeScript modules
- Create test files for React components
- Add missing test coverage to existing code
- Need Jest-specific patterns (mocks, spies, snapshots)
Test File Naming
Source to Test Mapping:
src/components/Feature.tsx→src/components/Feature.test.tsxsrc/utils/validator.ts→src/utils/validator.test.tssrc/models/User.ts→src/models/User.test.ts
Running Tests
# Preferred: Using bun (faster)
bun test
# Run specific file
bun test src/utils/validator.test.ts
# Run with coverage
bun test --coverage
# Watch mode
bun test --watch
# Alternative: Using npm
npm test
npm test -- --coverage
Jest Test Structure
import { functionToTest, ClassToTest } from './Feature'
jest.mock('./dependency')
describe('ModuleName', () => {
beforeEach(() => {
jest.clearAllMocks()
})
afterEach(() => {
jest.restoreAllMocks()
})
Details
- Repository
- github.com/secondsky/claude-skills
- Categories
- Testing & QA, Frontend & UI Code
- First seen
- Jun 3, 2026
Questions
What does the jest-generator skill do?
The jest-generator skill writes Jest unit tests for JavaScript and TypeScript code, including React components. It applies Jest conventions with proper mocking, describe blocks, spies, snapshots and async and timer tests.
How do I install the jest-generator skill?
Run npx -y skills add secondsky/claude-skills --skill jest-generator -y in your project to install the jest-generator skill. Once installed, jest-generator lets your agent generate Jest tests for your modules and components.
Which testing category does jest-generator belong to?
The jest-generator skill sits in the Testing & QA category on Claude Marketplaces. Its sibling skills there include tdd, migrate-to-shoehorn, test-driven-development, webapp-testing and break-ui.
Can jest-generator help with missing test coverage?
Yes, the jest-generator skill adds missing test coverage to existing JavaScript and TypeScript code. It names test files after their source modules and aims for at least 80% coverage with happy path, edge case and error tests.
More from secondsky/claude-skills
All 116- Thesys Generative Ui392
- Nuxt Studio390
- Maz Ui389
- Woocommerce Code Review388
- Woocommerce Backend Dev387
- Woocommerce Copy Guidelines383
- Woocommerce Dev Cycle383
- Nuxt Seo344
- Tailwind V4 Shadcn8.3K
- Aceternity Ui1.6K
- Vitest Testing1.3K
- Motion1.2K
- Playwright1.1K
- Api Testing924
- Responsive Web Design728
- Zod674
- Nano Banana Prompts645
- Mobile First Design621
- Image Optimization618
- Rest Api Design609
- Web Performance Optimization594
- Inspira Ui585
- Web Performance Audit563
- Api Authentication561
Similar to Jest Generator
More Testing & QAjavascript-typescript-jestgithub/awesome-copilot14.7K installsBest practices for Jest tests in JavaScript and TypeScript covering structure, mocking, async code, and React.
senior-qaalirezarezvani/claude-skills1.3K installsGenerates Jest, React Testing Library, MSW, and Playwright tests for React and Next.js apps.
javascript-testing-patternswshobson/agents21.6K installsComprehensive testing guide covering Jest and Vitest setup, unit, async, and mocking patterns for JavaScript and TypeScript.
unit-test-generatorpatricio0312rev/skills382 installsGenerates unit tests in AAA form with edge cases, error paths, and coverage checks for TypeScript code.
vitest-testingsecondsky/claude-skills1.3K installsModern Vitest guide for TypeScript and JavaScript tests, covering unit, integration, mocking, and coverage workflows.
unit-testing-test-generatesickn33/agentic-awesome-skills431 installsGenerate comprehensive unit tests across languages, with scaffolds for pytest, Jest, and React component testing.