diff --git a/app/components/league/__tests__/StandingsPreview.test.tsx b/app/components/league/__tests__/StandingsPreview.test.tsx index d692858..14b7636 100644 --- a/app/components/league/__tests__/StandingsPreview.test.tsx +++ b/app/components/league/__tests__/StandingsPreview.test.tsx @@ -70,8 +70,10 @@ describe("StandingsPreview", () => { ]; renderWithRouter(); - expect(screen.getByText("Team Alpha")).toBeInTheDocument(); - expect(screen.getByText("Team Beta")).toBeInTheDocument(); + // Use selector to target only the

element — the team name also appears + // in the SVG for accessibility, causing multiple matches otherwise. + expect(screen.getByText("Team Alpha", { selector: "p" })).toBeInTheDocument(); + expect(screen.getByText("Team Beta", { selector: "p" })).toBeInTheDocument(); }); it("renders owner name below team name", () => {