From eb2ac9197d9b0f76ae46d8fcf7fc849638df25e5 Mon Sep 17 00:00:00 2001 From: Said Date: Tue, 20 Oct 2026 14:37:05 +0100 Subject: [PATCH] test: keep weather teardown browser actively rendering --- changelog.d/1275-forecast-issue-fix.md | 1 + scripts/qa-weather-teardown.mjs | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/changelog.d/1275-forecast-issue-fix.md b/changelog.d/1275-forecast-issue-fix.md index 6168e7f1f..2013bc4f2 100644 --- a/changelog.d/1275-forecast-issue-fix.md +++ b/changelog.d/1275-forecast-issue-fix.md @@ -1,2 +1,3 @@ - Preserve enable during first-load replacement (asturksever, #1275). - Release disabled weather camera listeners and make teardown resource leaks fail the browser probe (asturksever, #1275). +- Keep visible-page weather teardown probes focused through the browser testing API (asturksever, #1275). diff --git a/scripts/qa-weather-teardown.mjs b/scripts/qa-weather-teardown.mjs index c81a7bec1..bf7b00269 100644 --- a/scripts/qa-weather-teardown.mjs +++ b/scripts/qa-weather-teardown.mjs @@ -61,6 +61,10 @@ const browser = await puppeteer.launch({ const boot = async () => { const page = await browser.newPage(); + // This probe measures active rendering; an OS-minimized window must not + // silently exercise the application's intentional hidden-page pause. + const focus = await page.createCDPSession(); + await focus.send('Emulation.setFocusEmulationEnabled', { enabled: true }); await page.setViewport({ width: 1400, height: 920, deviceScaleFactor: 1 }); const errors = []; page.on('pageerror', (e) =>