Skip to main content

Unit Testing Skills for AI Agents

Unit testing skills for AI coding agents. Jest, Vitest, pytest, and more — curated testing expertise for your AI pair programmer.

npx qaskills add jest-unit

What is Unit Testing?

Unit testing verifies that individual functions, methods, and components work correctly in isolation. By testing the smallest units of code independently, developers catch bugs early in the development cycle before they compound into larger issues. Modern unit testing frameworks like Jest, Vitest, and pytest provide powerful features including mocking, spying, snapshot testing, and code coverage analysis. These skills teach your AI agent proven patterns for writing fast, deterministic unit tests with proper test isolation, assertion strategies, and mock management.

74 skills available

Jest Unit Testing

by thetestingacademy

91

Jest unit testing patterns with mocking, spies, snapshots, and async testing

unit
jest
6491/100
Featured

React Testing Library

by thetestingacademy

91

User-centric React component testing with queries, events, and async utilities

unit
integration
jest
5391/100
Featured

Vitest Unit Testing

by thetestingacademy

89

Blazing fast Vite-native unit testing with Jest-compatible API and ESM support

unit
jest
4289/100
Featured

Pytest Patterns

by thetestingacademy

88

Python testing with pytest fixtures, parametrize, markers, and plugins

unit
integration
pytest
4188/100

MSW API Mocking

by thetestingacademy

88

Mock Service Worker for seamless API mocking in browser and Node.js environments

unit
integration
jest
3388/100

Vue Testing Utils

by thetestingacademy

87

Official Vue.js testing utilities for component mounting, mocking, and assertions

unit
jest
3187/100

Code Coverage Analysis

by thetestingacademy

85

Track test coverage with Istanbul/nyc, generate reports, and enforce thresholds

unit
code-quality
jest
3085/100

Storybook Component Testing

by thetestingacademy

87

Test React, Vue, and Angular components in isolation with Storybook interactions and play functions

unit
visual
jest
2987/100

Angular Testing

by thetestingacademy

86

Angular TestBed component testing with dependency injection, async testing, and Jasmine

unit
integration
jest
2486/100

Snapshot Testing

by thetestingacademy

82

Component and API snapshot testing to detect unexpected changes across releases

unit
visual
jest
2082/100

TDD Red-Green-Refactor

by thetestingacademy

83

Test-driven development workflow patterns with red-green-refactor cycle and refactoring techniques

tdd
unit
jest
1983/100

Test Data Generation

by thetestingacademy

83

Test data strategies using Faker.js, factories, builders, and database seeding

unit
integration
e2e
1883/100

Test Isolation Strategies

by qaskills

86

Test isolation techniques including database cleanup, transaction rollback, parallel test execution, and shared resource management.

unit
integration
1786/100

LibFuzzer Coverage-Guided Fuzzing

by qaskills

84

Coverage-guided fuzz testing using libFuzzer for C/C++ applications to find memory corruption, buffer overflows, and crash-inducing inputs.

security
unit
libfuzzer
1784/100

Mutation Testing

by thetestingacademy

86

Test quality verification with Stryker mutation testing for JavaScript and TypeScript

unit
code-quality
jest
1786/100

Test-Driven Development (TDD)

by thetestingacademy

81

Master the Test-Driven Development approach with Red-Green-Refactor cycles, writing tests before code, comprehensive coverage patterns, and quality code practices for building robust, maintainable software.

unit
integration
functional
jest
pytest
1681/100

Flutter Testing Patterns

by qaskills

82

Flutter app testing with widget tests, integration tests, golden tests, Mockito, bloc testing, and Flutter Driver for end-to-end scenarios.

unit
integration
e2e
flutter
1682/100

Test Fixture Patterns

by qaskills

82

Test fixture design patterns including builders, factories, object mothers, and fixture management for maintainable test data setup.

unit
integration
1682/100

TDD Red-Green-Refactor

by qaskills

82

Test-Driven Development mastery with red-green-refactor cycle, outside-in TDD, test-first design, and incremental development patterns.

unit
integration
1682/100

Svelte Component Testing

by qaskills

82

Svelte component testing with @testing-library/svelte, vitest, component rendering, event simulation, store testing, and SvelteKit testing.

unit
integration
svelte
vitest
1682/100

Go Testing Patterns

by qaskills

87

Go testing with testing package, table-driven tests, subtests, benchmarks, test fixtures, httptest, and testify assertions.

unit
integration
1687/100

Approval Testing

by qaskills

83

Approval testing methodology using ApprovalTests library for verifying complex outputs against human-approved results with diff-based review.

unit
integration
1583/100

Swift Testing Patterns

by qaskills

89

Swift testing with XCTest, Swift Testing framework, async/await testing, SwiftUI preview testing, and performance measurement.

unit
integration
xctest
1589/100

Mocha Testing Framework

by thetestingacademy

81

Flexible JavaScript testing framework with async support, hooks, and rich reporter ecosystem

unit
integration
jest
1581/100

MSW Mock Service Worker

by qaskills

81

API mocking with Mock Service Worker for browser and Node.js environments including request interception, response simulation, and network error testing.

unit
integration
msw
1481/100

Custom Static Analysis Rules

by qaskills

82

Writing custom static analysis rules for ESLint, Semgrep, and SonarQube to enforce project-specific code quality and security standards.

security
unit
1482/100

FastAPI Testing Patterns

by qaskills

84

FastAPI application testing with TestClient, dependency injection overrides, async testing, database testing with SQLAlchemy, and OpenAPI validation.

unit
integration
api
fastapi
pytest
1484/100

Cargo Fuzz Testing

by qaskills

80

Fuzz testing for Rust applications using cargo-fuzz and libFuzzer to discover memory safety issues, panics, and undefined behavior.

security
unit
cargo-fuzz
1380/100

Express.js Testing Patterns

by qaskills

80

Express.js API testing with supertest, middleware testing, route handler testing, error handling verification, and authentication testing.

unit
integration
api
express
jest
1380/100

Vue Test Utils Testing

by qaskills

84

Vue.js component testing using Vue Test Utils with mount/shallow mount, event simulation, Vuex/Pinia store testing, and composition API testing.

unit
integration
vue
1384/100

Property-Based Testing

by thetestingacademy

84

Generative testing with fast-check to discover edge cases automatically

unit
tdd
jest
1384/100

Library Backward Compatibility

by qaskills

86

Testing library backward compatibility including public API surface verification, semver compliance, TypeScript type compatibility, and migration path validation.

contract
unit
1386/100

Test Doubles Patterns

by qaskills

82

Comprehensive guide to test doubles including mocks, stubs, spies, fakes, and dummies with when-to-use guidelines and anti-pattern avoidance.

unit
1282/100

Test Coverage Gap Finder

by Pramod

87

Identify untested code paths, uncovered branches, and missing test scenarios using coverage analysis, risk mapping, and change-based coverage tracking

code-quality
unit
jest
vitest
1287/100

Debugging Strategies

by thetestingacademy

85

Advanced debugging patterns for test failures covering root cause analysis, flakiness investigation, performance debugging, and systematic troubleshooting methodologies.

e2e
unit
integration
playwright
cypress
1285/100

Test Suite Performance

by qaskills

81

Optimizing test suite execution speed with parallelization, test splitting, caching, selective test execution, and test impact analysis.

unit
integration
1281/100

Test Parameterization Patterns

by qaskills

88

Data-driven testing with parameterized tests, test matrices, combinatorial testing, and pairwise parameter generation techniques.

unit
integration
1288/100

NestJS Testing Patterns

by qaskills

82

NestJS application testing with @nestjs/testing, dependency injection mocking, e2e testing with supertest, guard testing, and pipe validation testing.

unit
integration
api
nestjs
jest
1282/100

Test Data Factory

by Pramod

87

Build reusable test data factories with builder patterns, realistic fake data generation, relationship handling, and database seeding for consistent test environments

unit
integration
e2e
jest
vitest
1187/100

Ruby on Rails Testing

by qaskills

87

Rails application testing with RSpec, FactoryBot, Capybara, system tests, request specs, model specs, and Rails-specific testing conventions.

unit
integration
e2e
rails
rspec
1187/100

Laravel Testing Patterns

by qaskills

89

Laravel PHP testing with PHPUnit, feature tests, browser tests with Dusk, database factories, mocking facades, and HTTP testing helpers.

unit
integration
e2e
laravel
phpunit
1189/100

Negative Test Generator

by Pramod

87

Systematically generate negative test cases covering invalid inputs, unauthorized actions, missing required fields, exceeded limits, and malformed request payloads

unit
integration
security
jest
vitest
1187/100

Flask Testing Patterns

by qaskills

86

Flask application testing with test client, fixture patterns, SQLAlchemy model testing, blueprint testing, and Flask-specific extension testing.

unit
integration
api
flask
pytest
1186/100

Boundary Value Generator

by Pramod

86

Generate boundary value test cases for numeric ranges, string lengths, date ranges, collection sizes, and domain-specific constraints using systematic analysis techniques

unit
integration
jest
vitest
1086/100

Error Boundary Tester

by Pramod

86

Validate error boundary implementations in React and other frameworks ensuring graceful degradation, proper fallback UI rendering, and error recovery flows

e2e
unit
playwright
jest
986/100

JavaScript Testing Patterns

by thetestingacademy

87

Modern JavaScript testing strategies with Jest, Mocha, and testing best practices covering unit testing, integration testing, mocking, async patterns, and DOM testing.

unit
integration
jest
987/100

State Machine Test Generator

by Pramod

86

Generate comprehensive test cases from state machine models covering all states, transitions, guard conditions, and invalid transition attempts for workflow-heavy features

unit
integration
jest
vitest
986/100

Mutation Test Generator

by Pramod

86

Generate and evaluate mutation tests to assess test suite effectiveness by introducing controlled code mutations and verifying test detection rates

unit
code-quality
jest
vitest
986/100

Smart Contract Testing

by qaskills

80

Smart contract testing with Hardhat, Foundry, and Brownie including unit tests, gas optimization, reentrancy checks, and fork testing.

unit
security
hardhat
foundry
880/100

Test Plan Generation

by thetestingacademy

80

Generate comprehensive test plans with coverage matrices and risk-based testing

e2e
integration
unit
880/100

Pairwise Test Generator

by Pramod

85

Generate optimized test combinations using pairwise (all-pairs) testing algorithms to achieve maximum coverage with minimum test cases across multiple input parameters

unit
integration
jest
vitest
885/100

Cypress Component Testing

by qaskills

80

Component testing with Cypress including mount API, React/Vue/Angular component testing, stub patterns, and visual snapshot testing.

unit
integration
cypress
880/100

Error Handling Testing Patterns

by qaskills

89

Testing error handling paths including exception propagation, error boundaries, retry logic, circuit breakers, and graceful degradation.

unit
integration
789/100

Golden File Testing

by qaskills

89

Golden file testing pattern for comparing output against approved baselines with update workflows, diff tools, and version control integration.

unit
integration
789/100

Verification Before Completion

by obra

83

Enforces rigorous verification evidence before any claims of task completion, preventing false positives, untested deployments, and premature celebration with a structured gate function.

e2e
integration
unit
683/100

Component Isolation Testing

by qaskills

80

Isolating and testing individual UI components with dependency mocking, state injection, and visual snapshot verification.

unit
visual
680/100

Configuration Testing

by qaskills

88

Testing application configurations including environment variable validation, feature flag combinations, config file parsing, and default value verification.

integration
unit
688/100

Kotlin Testing Patterns

by qaskills

85

Kotlin testing with JUnit 5, MockK, Kotest, coroutine testing, Android testing with Espresso, and Kotlin-specific assertion libraries.

unit
integration
junit
kotest
585/100

Advanced Mutation Testing

by qaskills

85

Advanced mutation testing using Stryker, PIT, and mutmut to measure test suite quality by introducing controlled mutations and tracking kill rates.

unit
stryker
585/100

Spring Boot Testing

by qaskills

83

Spring Boot application testing with @SpringBootTest, MockMvc, @DataJpaTest, Testcontainers, and Spring Security testing patterns.

unit
integration
spring-boot
junit
583/100

Python Testing Patterns

by thetestingacademy

81

Comprehensive Python testing best practices with pytest, covering unit testing, integration testing, mocking, fixtures, property-based testing, and test architecture.

unit
integration
pytest
581/100

Next.js Testing Patterns

by qaskills

84

Next.js application testing covering Server Components, App Router, API routes, middleware, dynamic routes, and SSR/SSG testing patterns.

unit
integration
e2e
nextjs
484/100

Faker Test Data Generation

by qaskills

86

Generating realistic test data with Faker libraries for names, addresses, emails, dates, and domain-specific data with reproducible seed control.

unit
integration
faker
486/100

WebAssembly Testing

by qaskills

86

Testing WebAssembly modules including compilation verification, memory management, interop testing, and performance benchmarking of WASM components.

unit
performance
486/100

Test Coverage Optimization

by qaskills

89

Optimizing test coverage beyond line coverage including branch coverage, mutation score, path coverage, and identifying meaningful coverage gaps.

unit
integration
489/100

Serverless Function Testing

by qaskills

80

Testing serverless functions including Lambda, Cloud Functions, and Edge Functions with local emulation, cold start testing, and timeout handling.

unit
integration
480/100

Rust Testing Patterns

by qaskills

86

Rust testing with built-in test framework, integration tests, doc tests, property-based testing with proptest, and cargo test configuration.

unit
integration
486/100

Nock HTTP Request Mocking

by qaskills

80

HTTP request mocking with Nock for Node.js testing including request intercepting, response recording, and external API simulation.

unit
integration
nock
480/100

.NET Testing Patterns

by qaskills

80

.NET testing with xUnit, NUnit, MSTest, FluentAssertions, Moq, integration testing with WebApplicationFactory, and Entity Framework testing.

unit
integration
xunit
nunit
380/100

Vitest Testing

by thetestingacademy

87

Modern JavaScript and TypeScript testing with Vitest, covering unit testing, integration testing, mocking, snapshots, browser mode, and Vite integration.

unit
integration
387/100

Event Sourcing Testing

by qaskills

82

Testing event sourcing patterns including event store validation, projection testing, saga orchestration, and event versioning compatibility.

unit
integration
382/100

Django Testing Patterns

by qaskills

86

Django application testing with TestCase, fixtures, factory_boy, model testing, view testing, middleware testing, and Django REST framework testing.

unit
integration
django
pytest
386/100

Concurrency Testing Patterns

by qaskills

84

Testing concurrent code including race condition detection, deadlock prevention, thread safety verification, and parallel execution correctness.

unit
integration
384/100

Hermetic Test Patterns

by qaskills

82

Building hermetic tests that are fully isolated from external dependencies using fakes, containers, and deterministic time/random sources.

unit
integration
382/100