diff --git a/src/app/features/tasks/task-detail-panel/task-detail-panel.component.spec.ts b/src/app/features/tasks/task-detail-panel/task-detail-panel.component.spec.ts index 64f911b4e6..60cb2e9ac9 100644 --- a/src/app/features/tasks/task-detail-panel/task-detail-panel.component.spec.ts +++ b/src/app/features/tasks/task-detail-panel/task-detail-panel.component.spec.ts @@ -410,7 +410,9 @@ describe('TaskDetailPanelComponent notes target does not auto-edit', () => { const focusItemSpy = spyOn(component, 'focusItem'); fixture.detectChanges(); // ngAfterViewInit subscribes; target emits after delay(50) - tick(50); + // Advance beyond the delay instead of relying on tasks scheduled for the + // exact same virtual timestamp. + tick(100); // The notes section is focused... expect(focusItemSpy).toHaveBeenCalledWith(noteItem);