MCPcopy
hub / github.com/angular/angular / TestComponent

Class TestComponent

packages/core/test/acceptance/animation_spec.ts:93–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

91 it('should delay element removal when an animation is specified', fakeAsync(() => {
92 const logSpy = jasmine.createSpy('logSpy');
93 @Component({
94 changeDetection: ChangeDetectionStrategy.Eager,
95 selector: 'test-cmp',
96 styles: styles,
97 template:
98 '<div>@if (show()) {<p animate.leave="fade" (animationend)="logMe($event)">I should fade</p>}</div>',
99 encapsulation: ViewEncapsulation.None,
100 })
101 class TestComponent {
102 show = signal(true);
103
104 logMe(event: AnimationEvent) {
105 logSpy();
106 }
107 }
108
109 TestBed.configureTestingModule({animationsEnabled: true});
110

Callers

nothing calls this directly

Calls 6

ComponentInterface · 0.90
signalFunction · 0.90
injectFunction · 0.90
computedFunction · 0.90
removeMethod · 0.65
addMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…