From 24ab7732839aee4d3540e7ee0c039c62325a8554 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BE=B7=E5=AE=87?= Date: Wed, 2 Sep 2026 13:15:34 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A8=B3=E5=AE=9A=20GDD=20=E6=81=A2=E5=A4=8D?= =?UTF-8?q?=E5=BC=B9=E5=B1=82=E6=B5=8B=E8=AF=95=E6=97=B6=E5=BA=8F=20?= =?UTF-8?q?=E7=AD=89=E5=BE=85=E5=88=9D=E5=A7=8B=20hydrate=20=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E5=90=8E=E5=86=8D=E6=96=AD=E8=A8=80=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E5=8F=AF=E7=94=A8=20=E4=BF=9D=E7=95=99?= =?UTF-8?q?=E6=81=A2=E5=A4=8D=E6=9C=9F=E9=97=B4=E7=A6=81=E7=94=A8=E6=8F=90?= =?UTF-8?q?=E4=BA=A4=E5=92=8C=E8=BE=93=E5=85=A5=E5=86=85=E5=AE=B9=E5=9B=9E?= =?UTF-8?q?=E5=BD=92=E9=AA=8C=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../tests/appSurface/plan-gdd.suite.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/apps/ai-game-creator-shell/tests/appSurface/plan-gdd.suite.ts b/apps/ai-game-creator-shell/tests/appSurface/plan-gdd.suite.ts index fe387dd7d..d63bb13b1 100644 --- a/apps/ai-game-creator-shell/tests/appSurface/plan-gdd.suite.ts +++ b/apps/ai-game-creator-shell/tests/appSurface/plan-gdd.suite.ts @@ -250,13 +250,15 @@ export function registerPlanGddApprovalTests() { const dialog = openReviseDialog(); const textarea = typeComment(dialog, '战斗节奏太慢,请压缩到三个回合'); - expect( - ( - within(dialog).getByRole('button', { - name: '提交决定', - }) as HTMLButtonElement - ).disabled, - ).toBe(false); + await waitFor(() => { + expect( + ( + within(dialog).getByRole('button', { + name: '提交决定', + }) as HTMLButtonElement + ).disabled, + ).toBe(false); + }); // 弹层是打开之后才被后台 hydrate 翻掉决定资格的:触发按钮的 disabled 管不到它。 harness.setPlanGddState(createPlanGddStateView({ recoveryPending: true }));