angular / angular/components

Some symbols not picked up by documentation infrastructure

Offen
#32,783 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
area: dev-infra docs P3
Vorherrschende Sprache
TypeScript
Sterne
25k
Forks
6.8k
Ø Merge
1 T. 8 Std.
Gemergte PRs (30 T.)
91

Beschreibung

### Is this a regression?

- [ ] Yes, this behavior used to work in the previous version

### 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.)

```ts
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):

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne damit, den Fehler beim Schließen des MatSelect-Overlays in der JSDOM-Testumgebung zu reproduzieren, und verfolge, wo auf das CSS-Animationsevent animationend gewartet wird. Vergleiche diesen Pfad mit dem bereitgestellten TestBed-Workaround unter Verwendung von ANIMATION_MODULE_TYPE und provideNoopAnimations(); als erledigt gilt die Identifizierung und Dokumentation eines standardisierten Testpfads.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
angular, typescript
Bereich
frontend, testing
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.