Is this a regression?
The previous version in which this bug was not present was
No response
Description
MatSelect waits for a CSS animationend event to close, which never fires in the JSDOM test environment.
- Zone change detection works
- Zoneless CD with
provideNoopAnimations() works
Since (a) the dependency on the animations package was removed in Sept 2025, and (b) within the animations package, provideNoopAnimations() is scheduled to go away in v23, I am wondering what the recommended path will be.
Our current workaround is to inject ANIMATION_MODULE_TYPE in our tests. e.g.)
await TestBed.configureTestingModule({
imports: [...],
providers: [
provideZonelessChangeDetection(),
{ provide: ANIMATION_MODULE_TYPE, useValue: 'NoopAnimations' },
],
}).compileComponents();
Reproduction
StackBlitz link:
Steps to reproduce:
1.
2.
Expected Behavior
A standardized way to test without provideNoopAnimations().
Actual Behavior
Tests that depend on waiting for the mat-select overlay to close fail.
Environment
- Angular:
- CDK/Material:
- Browser(s):
- Operating System (e.g. Windows, macOS, Ubuntu):