Repository navigation
test: synchronize async effects while preserving negative assertions - #160
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🤖 Review(中文)概要:本 PR 只改测试:把 FloatingPanel 和 NumberInput 测试里靠猜的 10/40/35ms 延时,换成等待真实的回调条件或 结论:整体方向很好,可以合并;下面几点是小建议,不阻塞。 建议
做得好的地方
|
🤖 Review (English)Summary: Test-only change. It replaces guessed 10/40/35ms sleeps in the FloatingPanel and NumberInput tests with waits on the real callback conditions or a Verdict: Good direction, fine to merge. The points below are minor and non-blocking. Suggestions
What's good
|
🤖 レビュー(日本語)概要:テストのみの変更です。FloatingPanel と NumberInput のテストで推測に頼っていた 10/40/35ms の待機を、実際のコールバック条件や 結論:方向性は良く、マージして問題ありません。以下は軽微な提案で、ブロッカーではありません。 提案
良い点
|
|
Addressed the timing-coverage suggestions in 6721e71:
Independent static re-review found no blocking issue. Kept draft while the new head's full CI reruns; the previous head's green checks are not being treated as validation of this follow-up. |
Summary
Fixes #155.
rafcallback.waitFor.No production behavior, skipped-test cleanup, Node policy, or release changes.
Verification
6721e714dd136062c282588b8d7b35b03f428134, including full CI/type checks, docs validation/build, all four Storybooks, packed consumers, lint, and browser accessibility smoke. Full CI evidence.Need help on this PR? Tag
@codesmith-botwith what you need.Note
Low Risk
Test-only timing and assertion refactors; no production code paths change.
Overview
Introduces a shared
assertAfterObservationWindowhelper (35ms) so tests can prove no late callbacks fire after unmount or controlled vetoes—somethingvi.waitForcannot do because it would pass on initial silence.React and Vue controllable-migration dialog lifecycle tests use the helper instead of inline
setTimeout(35). FloatingPanel unit tests drop guessed 10/40ms sleeps: positive work waits onvi.waitForfor real callback/state conditions, then the observation window guards against extraonOpenChangeechoes. NumberInput caret tests wait onerequestAnimationFrame(documented as matching core reconciliation) instead of a fixed 35ms delay.Adds a small unit test for the observation-window behavior (including a negative control that fails if the wait is removed).
Reviewed by Cursor Bugbot for commit 6721e71. Bugbot is set up for automated code reviews on this repo. Configure here.