From 8d2d514fa76a901c40c186f51266ec1abd1e2ffa Mon Sep 17 00:00:00 2001 From: WeiCHEN Date: Tue, 22 Sep 2026 22:01:13 +0800 Subject: [PATCH] =?UTF-8?q?fix(e2e):=20exit=20AdminConsoleView=20via=20?= =?UTF-8?q?=E8=BF=94=E5=9B=9E=E5=B7=A5=E4=BD=9C=E5=8F=B0=20in=20UI-00?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/e2e/document-revision-runtime.spec.ts | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/web/e2e/document-revision-runtime.spec.ts b/web/e2e/document-revision-runtime.spec.ts index 4869824b..f6a469b3 100644 --- a/web/e2e/document-revision-runtime.spec.ts +++ b/web/e2e/document-revision-runtime.spec.ts @@ -707,13 +707,9 @@ test.describe.serial('document-revision-runtime UI acceptance', () => { await adminCreateUser(page, USER_A, `编制人A-${suffix}`, INIT_PASS, 'role-tech-lead'); await adminCreateUser(page, USER_B, `协作者B-${suffix}`, INIT_PASS, 'role-engineer'); await adminCreateUser(page, USER_C, `无关人C-${suffix}`, INIT_PASS, 'role-guest'); - // Close through the real top-right X, scoped to the outer fixed admin modal. - const adminHeading = page.getByText('系统管理控制台', { exact: true }); - const adminModal = adminHeading.locator( - 'xpath=ancestor::div[contains(@style,"position: fixed")][1]', - ); - await adminModal.locator('button').first().click(); - await expect(adminHeading).toBeHidden({ timeout: 10_000 }); + // Full-page AdminConsoleView (not the old fixed modal): exit via 返回工作台. + await page.getByRole('button', { name: '返回工作台' }).click(); + await expect(page.getByText('新建立项会话')).toBeVisible({ timeout: 15_000 }); await logoutViaUI(page); // A first login + password change