MCPcopy Index your code
hub / github.com/angular/angular / getCleanupHook

Function getCleanupHook

packages/core/testing/src/test_hooks.ts:30–38  ·  view source on GitHub ↗
(expectedTeardownValue: boolean)

Source from the content-addressed store, hash-verified

28globalThis.afterEach?.(getCleanupHook(true));
29
30export function getCleanupHook(expectedTeardownValue: boolean): VoidFunction {
31 return () => {
32 const testBed = TestBedImpl.INSTANCE;
33 if (testBed.shouldTearDownTestingModule() === expectedTeardownValue) {
34 testBed.resetTestingModule();
35 resetFakeAsyncZoneIfExists();
36 }
37 };
38}

Callers 1

test_hooks.tsFile · 0.85

Calls 3

resetTestingModuleMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…