Repository navigation
fix(tests): Use webActorFromUser in web batch test - #2643
Merged
Merged
Conversation
A scroll event fires on the next frame. When the test grew content above the reader in the same frame, the transcript recorded the reader's place after the growth, so it made no correction and the message left the viewport. The test now waits one frame after each scroll. Co-Authored-By: David Cramer <23610+dcramer@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
thomasjiangcy
marked this pull request as ready for review
November 4, 2026 07:21
thomasjiangcy
approved these changes
Nov 4, 2026
This was referenced Nov 4, 2026
This branch was successfully deployed
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.
Main CI on 38c8693 (#2625) fails
check / types,test / junior unit, andtest / dashboard e2e.Types and unit. #2625 added
web-batch-messages.test.tswithwebActorFromEmail. #2630 removed it. The test now useswebActorFromUser(testViewer(...)), the same fix as c1e36af in #2631.Dashboard e2e.
conversations-mobile.spec.ts"keeps the message in view while earlier history and late content load" is flaky. It is not a regression from #2622 or #2625:ReviewItemContext.tsx) and 38c8693. Passed only on retry on 38597fb. Each of these failed at line 752, the last step (spacer above the reader).scrollIntoViewIfNeeded()right before that step. The scroll event fires on the next frame. When the test appends the spacer first, the transcript's scroll handler records the reader's place from the layout that already has the spacer. The resize correction then sees no shift. Local logs showed this order in every failure and the opposite order in every pass.Still open. Under 4 parallel workers, 7 of the 160 local runs failed one step earlier (after the earlier page loads). I did not measure that step on main without this change. In the one failure I logged, the correction ran twice:
scrollTopmoved by exactly 2× the shift. That points to a product race intranscriptBottomPinning.ts, not a test race. This PR does not fix it. I have not seen it fail in CI.via @dcramer.
--
View Session [Sentry]