-
-
Notifications
You must be signed in to change notification settings - Fork 32.9k
assert,util: fail promise comparison in deep equal checks #59448
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
assert,util: fail promise comparison in deep equal checks #59448
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #59448 +/- ##
=======================================
Coverage 89.88% 89.89%
=======================================
Files 656 656
Lines 192947 192984 +37
Branches 37841 37858 +17
=======================================
+ Hits 173427 173474 +47
+ Misses 12054 12052 -2
+ Partials 7466 7458 -8
🚀 New features to boost your workflow:
|
Can this behaviour get a mention under the method descriptions in assert.md, as WeakMap/WeakSet do currently? |
There is a typo in commit message "it's state" -> "its state". |
It is impossible to look into the content of a promise and its state. This aligns the comparison with WeakMaps and WeakSets. Only reference equal promises will pass the check in the future. Fixes nodejs#55198
23edea2
to
74ff4a7
Compare
I just updated the docs and fixed the commit message typo. PTAL |
Landed in 7c9fbc1 |
It is impossible to look into the content of a promise and it's state. This aligns the comparison with WeakMaps and WeakSets. Only reference equal promises will pass the check in the future.
Fixes #55198