diff --git a/web/test/ui-smoke.mjs b/web/test/ui-smoke.mjs index 987f699c..e6a33b7c 100644 --- a/web/test/ui-smoke.mjs +++ b/web/test/ui-smoke.mjs @@ -2204,8 +2204,10 @@ try { await shot("50-chat-no-match.png"); await page.clickText(".chat-rows .empty button", "Clear search"); await page.waitForSelector("#chatRows .chat-row", { timeout: 10000 }); - const cleared = await page.evaluate(`document.querySelector("#chatSearch")?.value ?? null`); - if (cleared !== "") throw new Error(`Clear search left the query: ${JSON.stringify(cleared)}`); + const clearedQuery = await page.evaluate(`document.querySelector("#chatSearch")?.value ?? null`); + if (clearedQuery !== "") { + throw new Error(`Clear search left the query: ${JSON.stringify(clearedQuery)}`); + } const expectedSession = "ses_eae413f50ffeLQDExlg8cYnscN"; const openedId = chatList.rows[0].id;