angular-testing

Create unit and integration tests for Angular apps with Vitest and Jasmine.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/rensjaspers/agents --skill angular-testing-rensjaspers
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: angular-testing
Source: https://github.com/rensjaspers/agents/tree/main/skills/angular-testing
Command: npx skills add https://github.com/rensjaspers/agents --skill angular-testing-rensjaspers

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps developers write robust and efficient unit and integration tests for Angular applications, ensuring code quality and maintainability.

Core Features & Use Cases

  • Vitest/Jasmine Integration: Supports modern testing with Vitest and traditional Jasmine.
  • Signal-Based Components: Provides patterns for testing components utilizing Angular Signals.
  • Dependency Mocking: Demonstrates effective techniques for mocking services and HTTP requests.
  • Use Case: You need to write tests for a new Angular component that uses signals and depends on an HTTP service. This Skill provides the exact code snippets and setup instructions to achieve this quickly.

Quick Start

Use the angular-testing skill to generate a basic Vitest unit test for an Angular component.

Frequently Asked Questions about angular-testing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write unit tests for Angular signal-based components?

To unit test Angular signal-based components, you use TestBed to configure the testing module and interact with signal values directly. This Skill provides specific code patterns for testing signal reactivity within OnPush change detection.

Can I use Vitest instead of Jasmine for Angular testing?

Yes, Vitest can be used instead of Jasmine for Angular testing. This Skill supports both frameworks, providing setup instructions and code snippets for modern Vitest configurations alongside traditional Jasmine test patterns.

What is the best way to mock HTTP services in Angular integration tests?

Mocking HTTP services in Angular integration tests is best done using TestBed to inject test doubles. This Skill demonstrates effective dependency mocking techniques for HTTP interactions and services using the modern inject() syntax.

Does this Angular testing approach support components with OnPush change detection?

Yes, this Angular testing approach fully supports OnPush change detection. It provides specific testing patterns to ensure unit and integration tests correctly trigger and verify change detection cycles in your components.

How do I test Angular services that use the inject() function?

To test Angular services using the inject() function, configure TestBed with the necessary provider mocks. This Skill covers modern testing patterns to effectively mock dependencies and validate service behavior using inject().