-
-
Notifications
You must be signed in to change notification settings - Fork 481
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
pass tests in ReactFinalForm.test.js #578
pass tests in ReactFinalForm.test.js #578
Conversation
DO NOT MERGE without reading. This PR updates react to the new rc, and uses the new async act to silence a warning in ReactFinalForm.test.js Further, regarding Field.test.js, I rewrote `sleep` with `act`, and discovered some issues, and disabled some tests - 'should use isEqual to calculate dirty/pristine': This test goes into an infinite loop; it appears act() has caught an actual bug here. 'should `formatOnBlur` most updated value' and 'should pass multiple through to custom components' appear to be breaking some assumptions for react-dom, and should probably be fixed. I've included the warning messages that show for these warnings too.
d298aa1
to
a19f3e7
Compare
Of note, this also updates |
Codecov Report
@@ Coverage Diff @@
## master #578 +/- ##
=====================================
Coverage 100% 100%
=====================================
Files 16 16
Lines 233 233
Branches 57 57
=====================================
Hits 233 233 Continue to review full report at Codecov.
|
1 similar comment
Codecov Report
@@ Coverage Diff @@
## master #578 +/- ##
=====================================
Coverage 100% 100%
=====================================
Files 16 16
Lines 233 233
Branches 57 57
=====================================
Hits 233 233 Continue to review full report at Codecov.
|
Interesting, thanks for this! I'll try to look into those failing test to fix them. I've looked into |
That is correct, yes. But to clarify, generally/in sync mode, you don't have to directly wrap setState callsites either, anywhere above it (in the function callstack) should be fine. |
Yeah, sure - i meant exactly that by wrapping setState. Stack introspection is normally not possible in strict mode after all. Thanks for confirming that, cant wait for async act now 😄 |
Sweet, some love from the React team! Thanks, @Andarist and @threepointone. 👍 |
16.9 got released - gonna work on finishing this one soon(-ish). Thanks Sunil for showing how things should be done :) |
Implemented by #581. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
DO NOT MERGE without reading.
This PR updates react to the new rc, and uses the new async act to silence a warning in ReactFinalForm.test.js
Further, regarding Field.test.js, I rewrote
sleep
withact
, and discovered some issues, and disabled some tests -'should use isEqual to calculate dirty/pristine': This test goes into an infinite loop; it appears act() has caught an actual bug here.
'should
formatOnBlur
most updated value' and 'should pass multiple through to custom components' appear to be breaking some assumptions for react-dom, and should probably be fixed.I've included the warning messages that show for these warnings too.