From 78d7de1dfdce72e937783dc7fceb1a8ca711c0e5 Mon Sep 17 00:00:00 2001 From: Joshen Lim Date: Fri, 2 Oct 2026 13:57:07 +0800 Subject: [PATCH] fix(e2e): disambiguate Join a channel locator in realtime inspector helper Now that the Inspector can show MessagesTable's own "Join a channel to start listening to messages" empty state before a channel is joined, the loose text locator matches two elements and triggers a Playwright strict-mode violation. Scope it to the toolbar button. Co-Authored-By: Claude Sonnet 5 --- e2e/studio/utils/realtime-helpers.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/e2e/studio/utils/realtime-helpers.ts b/e2e/studio/utils/realtime-helpers.ts index d58dba5397f..20e381f00d4 100644 --- a/e2e/studio/utils/realtime-helpers.ts +++ b/e2e/studio/utils/realtime-helpers.ts @@ -3,7 +3,9 @@ import { toUrl } from './to-url.js' export async function navigateToRealtimeInspector(page: Page, ref: string) { await page.goto(toUrl(`/project/${ref}/realtime/inspector`)) - await expect(page.locator('text=Join a channel')).toBeVisible({ timeout: 30000 }) + await expect(page.getByRole('button', { name: 'Join a channel' })).toBeVisible({ + timeout: 30000, + }) } export async function joinChannel(page: Page, channelName: string) {