Angular library (v1.1.3, stable, no recent updates) that caches TestBed configurations between tests to reduce compilation overhead and speed up test suites. Key differentiator: minimal API (single function call) vs alternatives like angular-testing-library or custom caching. Requires @angular/core, rxjs, and zone.js as peer dependencies. Ships TypeScript types.
npm install ng-cache-testing-moduleNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic usage of cacheTestingModule() in a Jasmine test suite to cache TestBed configuration, improving performance.
Move cacheTestingModule() to the describe callback, outside beforeEach.
Replace useValue with useFactory in providers to create fresh instances each test.
Create spies inside individual it() blocks instead of shared setup.
Ensure cacheTestingModule() is called in every describe block that should use caching.
Use the NG_CACHE_MODULE_CONFIG injection token instead of importing ICacheTestingModuleConfig.
Refactor your Angular module to eliminate circular dependencies or avoid caching in that test suite.
Ensure cacheTestingModule() is called at the top level of the describe block.
Use import { cacheTestingModule } from 'ng-cache-testing-module' instead of require().Import the type using import type { ICacheTestingModuleConfig } from 'ng-cache-testing-module' with type-only import, or switch to NG_CACHE_MODULE_CONFIG token.