Closed
Description
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
16.2.12
Description
When upgrading from material 16.2.12 to 17.0.0 ; when a jest test runs and the class has a dependency to MatDialog:

Reproduction
StackBlitz link:
Steps to reproduce:
1.
2.
Expected Behavior
no crash
Actual Behavior
crash
Environment
- Angular: 17.0.3
- CDK/Material: 17.0.0
- Browser(s): any
- Operating System (e.g. Windows, macOS, Ubuntu): windows