Repository navigation
Dex Web: wait for the page-load search in the WorkQueueSearch test - #1629
Merged
Merged
Conversation
…ype test The test read its search-count baseline before the page-load search effect had run. Under load the effect landed later and the test counted it as a search caused by the checkbox. Wait for that search, then assert absolute counts. Fixes #1600
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
web/app/work-queue/WorkQueueSearch.test.tsx, "searches several Flow types in one request and offers all their Steps": wait until the page-load search has been sent, then assert absolute search counts (1 before submit, 2 after) instead of counts relative to a value read too early.Why
Issue #1600. The test failed intermittently in CI on unrelated PRs (#1584, #1574) with
expected 1 to be +0. Capturing the extra request's body under load showed{"flowTypes":["RefundFlow"],"filters":[]}: the page-load search, sent byuseFlowSearch's passive effect, which can run afterfindByTextreturns. The test sometimes readsearchesBeforeas 0 and then counted the page-load search as one triggered by the checkbox. The component is correct: the checkbox changesrunQuery.query.flowTypes, and the search effect follows only the applied Flow types, so no search is sent before submit.Test-only change; no user-visible change, so no change log fragment.
Testing
expected 1 to be +0); after the fix 0/50 sequential and 0/320 under the same load.tsc --noEmitpasses. (Run on Node 24, as CI uses 22/24.)Fixes #1600