From 803622bad1b9856dca66a453e4c1746428c6d3b2 Mon Sep 17 00:00:00 2001 From: Wickedness Date: Sun, 5 Jul 2026 17:32:44 +0900 Subject: [PATCH] Verify public page title --- scripts/verify-public-deploy.mjs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/verify-public-deploy.mjs b/scripts/verify-public-deploy.mjs index a6658ac..462a511 100644 --- a/scripts/verify-public-deploy.mjs +++ b/scripts/verify-public-deploy.mjs @@ -4,6 +4,7 @@ import { chromium } from 'playwright'; const targetUrl = withQaParams(process.env.PUBLIC_QA_URL ?? 'https://comtropy.synology.me/heros_web/'); const screenshotPath = process.env.PUBLIC_QA_SCREENSHOT ?? 'dist/public-deploy-qa.png'; +const expectedTitle = '삼국지: 세 형제의 맹세'; const relevantLogPattern = /asset|audio|cannot|failed|map|missing|portrait|sprite|story|texture|unit/i; mkdirSync(dirname(screenshotPath), { recursive: true }); @@ -87,7 +88,7 @@ try { } }); - assert(state.title?.trim().length > 0, `Expected deployed page title: ${JSON.stringify(state)}`); + assert(state.title === expectedTitle, `Expected deployed page title "${expectedTitle}": ${JSON.stringify(state)}`); assert(state.canvasCount === 1, `Expected exactly one game canvas: ${JSON.stringify(state)}`); assert(state.debugApiPresent === false, `Expected public deploy to keep debug API disabled: ${JSON.stringify(state)}`); assert(state.canvas?.width >= 960 && state.canvas?.height >= 540, `Expected desktop-size game canvas: ${JSON.stringify(state)}`);