From 7309ece5593c954cdfc460c92101679607f11e2d Mon Sep 17 00:00:00 2001 From: Delicious233 <101502465+DeliciousBuding@users.noreply.github.com> Date: Tue, 18 Aug 2026 04:41:31 +0800 Subject: [PATCH] =?UTF-8?q?fix(shared):=20SettingsPage=20=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=20aria-label=20=E6=96=AD=E8=A8=80=E5=AF=B9=E9=BD=90?= =?UTF-8?q?=20key-echo=20=E6=A8=A1=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit SettingsMain title="设置加载失败" 迁移到 tw("settings.loadFailed") 后, desktop/shared 测试 i18n 实例默认 'test' 语言(key-echo),tw() 返回 key 而非中文。将 SettingsPage.test.tsx 断言从 '设置加载失败' 改为 'settings.loadFailed' 匹配 key-echo 行为。 修复 PR #1750 引入的 frontend-desktop (1) 和 Frontend coverage baseline (@agenthub/shared) CI 失败。 Co-authored-by: Cursor --- app/shared/src/workbench/pages/SettingsPage.test.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/shared/src/workbench/pages/SettingsPage.test.tsx b/app/shared/src/workbench/pages/SettingsPage.test.tsx index 6f018af16..a5312cd42 100644 --- a/app/shared/src/workbench/pages/SettingsPage.test.tsx +++ b/app/shared/src/workbench/pages/SettingsPage.test.tsx @@ -64,7 +64,7 @@ describe('SettingsPage load/error UX', () => { />, ); - expect(screen.getByRole('alert', { name: '设置加载失败' })).toBeInTheDocument(); + expect(screen.getByRole('alert', { name: 'settings.loadFailed' })).toBeInTheDocument(); expect(screen.getByText('backend down')).toBeInTheDocument(); screen.getByRole('button', { name: '重试加载' }).click();