Skip to content

Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.

Go

test(views): wait per phase in the long-history deep-link landing test (MUL-9993) (#11329)

Jiayuan Zhang703470b341db
diff --git a/packages/views/issues/components/issue-detail.test.tsx b/packages/views/issues/components/issue-detail.test.tsx
index e0b0ee1369..d46cf64cba 100644
--- a/packages/views/issues/components/issue-detail.test.tsx
+++ b/packages/views/issues/components/issue-detail.test.tsx
@@ -3006,6 +3006,11 @@ describe("IssueDetail (shared)", () => {
mockApiObj.listTasksByIssue.mockResolvedValue([]);
renderIssueDetailWithHighlight(target.id);
+ // Wait phase by phase: page boot (issue + timeline queries, first
+ // commit), the jump mounting the target row, then the landing frames.
+ // On a loaded runner the three together outrun one waitFor's budget.
+ await screen.findByTestId("virtuoso-mock");
+ await waitFor(() => expect(document.getElementById(`comment-${target.id}`)).not.toBeNull());
await waitFor(() => expect(hasHighlightedCommentBackground(
document.getElementById(`comment-${target.id}`),
)).toBe(true));