From d58fe967a48b5d2f8c4287e1a5b43ecea183a9a9 Mon Sep 17 00:00:00 2001 From: claude code agent 227 Date: Wed, 1 Jul 2026 01:57:40 +0300 Subject: [PATCH] test(#268): assert the hover card's pointer-events:none (F1) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Lock the feature's central invariant — the tooltip must never intercept the comment-mark's click (which opens the side panel). pointer-events:none is the single property guaranteeing that, and it was unasserted: a regression dropping it from the style object would let a lingering card swallow the click with no test failing. Assert it in the "shows after delay" test. --- .../comment/components/comment-hover-preview.test.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/apps/client/src/features/comment/components/comment-hover-preview.test.tsx b/apps/client/src/features/comment/components/comment-hover-preview.test.tsx index 99c942fa..f35dbcdd 100644 --- a/apps/client/src/features/comment/components/comment-hover-preview.test.tsx +++ b/apps/client/src/features/comment/components/comment-hover-preview.test.tsx @@ -182,6 +182,10 @@ describe("CommentHoverPreview — hover behaviour", () => { }); const card = screen.getByTestId("comment-hover-preview"); expect(card.textContent).toBe("Hello world"); + // The card MUST NOT intercept the mark's click (which opens the side panel): + // pointer-events:none is the single property guaranteeing that — lock it so + // a regression dropping it from the style object fails here. + expect(card.style.pointerEvents).toBe("none"); }); it("hides on mouseout", () => {