components icon indicating copy to clipboard operation
components copied to clipboard

test(menu): remove provideZoneChangeDetection for all menu tests

Open atscott opened this issue 9 months ago • 0 comments

This removes 'provideZoneChangeDetection' from menu tests. Change summary:

  • Many tests set inputs directly. This isn't really how it happens in applications - inputs set from the template automatically mark components for check. When tests set inputs directly like this, they need to call markForCheck manually (or something similar).
  • One test seems to be calling a public API (CdkContextMenuTrigger.open) that failed to call markForCheck so that was added to the implementation
  • fakeAsync had an additional timer so I just added flush to make it work.

atscott avatar May 16 '24 18:05 atscott