From 9bf35e87457c338352706382ec3821fab179b622 Mon Sep 17 00:00:00 2001 From: kdletters Date: Mon, 21 Sep 2026 11:53:32 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20macOS=20=E6=9E=84=E5=BB=BA?= =?UTF-8?q?=E4=B8=8A=E7=9A=84=E6=B8=A0=E9=81=93=E7=8E=AF=E5=A2=83=E5=8F=98?= =?UTF-8?q?=E9=87=8F=E7=94=A8=E4=BE=8B=E5=AE=BF=E4=B8=BB=E4=BE=9D=E8=B5=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - build-release.test.mjs 的「packaged renderer receives the same channel as the updater manifest」用 windows target 却未注入 stageRuntime,真实 staging 要求宿主 Node 平台/架构与目标一致,导致 macOS(arm64)/Linux 上必然失败 - 该用例只断言传给 spawn 的 VITE_AGC_PLATFORM_CHANNEL,改为注入空 stageRuntime,与同文件其它用例一致 --- apps/ai-game-creator-shell/scripts/build-release.test.mjs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/ai-game-creator-shell/scripts/build-release.test.mjs b/apps/ai-game-creator-shell/scripts/build-release.test.mjs index 732302eb1..b5f8a44da 100644 --- a/apps/ai-game-creator-shell/scripts/build-release.test.mjs +++ b/apps/ai-game-creator-shell/scripts/build-release.test.mjs @@ -215,6 +215,9 @@ test('packaged renderer receives the same channel as the updater manifest', () = spawnOptions = options; return { status: 0 }; }, + // 该用例只关心渠道环境变量;Node 运行时 staging 与宿主平台绑定, + // 真实 staging 会让同一用例在 macOS/Linux 上对 windows target 失败。 + stageRuntime: () => {}, }); assert.equal(spawnOptions?.env?.VITE_AGC_PLATFORM_CHANNEL, 'release'); });