From daab41b5667cf481e8d7578d397e81c689b53751 Mon Sep 17 00:00:00 2001 From: yetone Date: Tue, 6 Oct 2026 05:01:18 +0800 Subject: [PATCH] =?UTF-8?q?gui=20tests:=20model-price-tiers=20types=20the?= =?UTF-8?q?=20tier's=20"over"=20amount=20and=20presses=20Enter=20=E2=80=94?= =?UTF-8?q?=20Chromium's=20fill=20selected=20the=20box,=20and=20its=20blur?= =?UTF-8?q?'s=20change=20pre-filled=20the=20input=20price=20with=201,=20so?= =?UTF-8?q?=20the=20price=20read=20"12,5".=20Passes=20in=20Chromium=20and?= =?UTF-8?q?=20WebKit,=20en=20and=20zh;=20failed=20in=20Chromium=20on=206e6?= =?UTF-8?q?23d16.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/gui/tests/model-price-tiers.test.cjs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/gui/tests/model-price-tiers.test.cjs b/internal/gui/tests/model-price-tiers.test.cjs index f5d38a13..b8a98575 100644 --- a/internal/gui/tests/model-price-tiers.test.cjs +++ b/internal/gui/tests/model-price-tiers.test.cjs @@ -105,7 +105,9 @@ for (const engine of (process.env.BROWSER ? [process.env.BROWSER] : ["chromium", assert.equal(await page.evaluate(() => document.activeElement?.getAttribute("aria-label")), L.over); await typeIn(row("plain-1").getByRole("textbox", { name: L.over, exact: true }), "lots"); await page.locator("#status", { hasText: L.badSize }).waitFor(); - await row("plain-1").getByRole("textbox", { name: L.over, exact: true }).fill("200k"); + // (Enter first: the size taken fills the price boxes from its own, and + // in Chromium a fill that blurs the size box lands after that fill) + await typeIn(row("plain-1").getByRole("textbox", { name: L.over, exact: true }), "200k"); await typeIn(row("plain-1").getByRole("textbox", { name: L.long + " ยท " + L.input, exact: true }), "2,5"); assert.deepEqual(await tier("plain-1").evaluateAll((is) => is.map((i) => i.value)), ["200K", "2.5", "4", "0.1", "0"]); assert.equal(await page.evaluate(() => scrollY), y, "nothing scrolled the page");