-
Notifications
You must be signed in to change notification settings - Fork 24.8k
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
fix(core): support cyclic metadata in TestBed overrides #44215
Conversation
The TestBed APIs to override metadata would crash when the metadata contained objects with cyclic references. Metadata overrides use the JSON serialized representation of a value to compare objects, which throws an error if the value has cyclic references. This commit avoids the error by replacing multiple occurrences of the same object using a unique string representation for the object. Fixes angular#43948
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the fix @JoostK 👍
Note to the Caretaker: global presubmit is "green" for this change. The |
This PR was merged into the repository by commit b930547. |
The TestBed APIs to override metadata would crash when the metadata contained objects with cyclic references. Metadata overrides use the JSON serialized representation of a value to compare objects, which throws an error if the value has cyclic references. This commit avoids the error by replacing multiple occurrences of the same object using a unique string representation for the object. Fixes #43948 PR Close #44215
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
The TestBed APIs to override metadata would crash when the metadata contained objects with cyclic references. Metadata overrides use the JSON serialized representation of a value to compare objects, which throws an error if the value has cyclic references. This commit avoids the error by replacing multiple occurrences of the same object using a unique string representation for the object. Fixes angular#43948 PR Close angular#44215
The TestBed APIs to override metadata would crash when the metadata
contained objects with cyclic references. Metadata overrides use the
JSON serialized representation of a value to compare objects, which
throws an error if the value has cyclic references. This commit avoids
the error by replacing multiple occurrences of the same object using
a unique string representation for the object.
Fixes #43948