From 9d1f4c19752fc706e76118a4ac09f52250e9b966 Mon Sep 17 00:00:00 2001 From: Linghong Date: Fri, 7 Aug 2026 02:55:26 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=A1=B9=E7=9B=AE=E5=88=87?= =?UTF-8?q?=E6=8D=A2=20manifest=20=E6=B5=8B=E8=AF=95=E7=AB=9E=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 等待 manifest 失效监听注册后再发送失效事件 避免 CI 中测试事件丢失导致超时 --- apps/ai-game-creator-shell/tests/appSurface/home.suite.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/apps/ai-game-creator-shell/tests/appSurface/home.suite.ts b/apps/ai-game-creator-shell/tests/appSurface/home.suite.ts index 1ff1f578f..1268caf86 100644 --- a/apps/ai-game-creator-shell/tests/appSurface/home.suite.ts +++ b/apps/ai-game-creator-shell/tests/appSurface/home.suite.ts @@ -461,6 +461,12 @@ export function registerClientHomeTests() { }); fireEvent.click(screen.getByRole('button', { name: '打开' })); await screen.findByLabelText('项目开发工作台'); + await waitFor(() => { + expect(runtimeHarness.listen).toHaveBeenCalledWith( + 'game-creator-manifest-invalidated', + expect.any(Function), + ); + }); holdFirstRefresh = true; act(() => { runtimeHarness.emitManifestInvalidated('code-prototype');