charhub-jest-patterns
CommunityStandardize Jest tests for CharHub backend.
Authorleandro-br-dev
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Writing consistent, reliable Jest tests for CharHub's Express/NestJS backend can be error-prone without established patterns. This Skill provides standardized testing patterns, mocking strategies, and a cohesive structure to reduce boilerplate and improve test quality.
Core Features & Use Cases
- Mocking Prisma with jest-mock-extended for deterministic tests.
- NestJS TestingModule patterns for unit and integration tests.
- Async testing patterns, error handling, and test isolation.
- Custom and common matchers to improve assertions.
- Test doubles (spies and stubs) to verify interactions.
- End-to-end guidance for structuring tests across controllers, services, and utilities.
Quick Start
Create a unit test for a NestJS service using mockDeep and Prisma mocks following the patterns in this guide.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: charhub-jest-patterns Download link: https://github.com/leandro-br-dev/charhub/archive/main.zip#charhub-jest-patterns Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.