-
Notifications
You must be signed in to change notification settings - Fork 309
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature]: Allow configuring errorOnUnknownElements
and errorOnUnknownProperties
for setup test env
#1656
Comments
PR is welcome, should be similar to #1475 I like this option
|
Yes, I'll do the PR |
@cedricduffournet @ahnpnl Can you guide me on how to use this ? I can't find docs about this setup-jest.js
and in jest.config.js
But it doesn't work when I execute |
@Yohandah this should work. |
@cedricduffournet I have a reproduction here : but using @angular-builders/jest ... https://github.com/Yohandah/angular-builder-jest-errorOnUnknownElementsr It could come from this package then ... |
@Yohandah I don't know about |
@cedricduffournet yeah that's because I've added the options directly inside Thanks anyway for trying to help ! |
@cedricduffournet I tried to enable these options using checkout the repo (jest-preset-angular-only branch): https://github.com/Yohandah/angular-builder-jest-errorOnUnknownElementsr/tree/jest-preset-angular-only |
🚀 Feature Proposal
Allow configuring
errorOnUnknownElements
anderrorOnUnknownProperties
is test environment optionsee: https://angular.io/api/core/testing/TestEnvironmentOptions
Motivation
This new properties has been introduce in angular V14. This is usefull to throw errors on unknown elements or properties found in a template
Example
like destroyAfterEach option, we could add
errorOnUnknownElements
anderrorOnUnknownProperties
As
TestEnvironmentOptions
may introduce more properties in the future, we could addtestEnvironmentOptions
property in config:The text was updated successfully, but these errors were encountered: