Remove selected-user sharing from cloud agent access UI

This commit is contained in:
2026-09-19 08:52:04 +08:00
parent 7fb4c60492
commit e04787763b
8 changed files with 94 additions and 31 deletions

View File

@@ -267,7 +267,7 @@ test('personal cloud Agent creation, draft save and leave protection in Electron
await expect(page.getByLabel('每日上限(词元点数)')).toHaveValue('10.00');
await page.getByRole('button', { name: '保存费用上限' }).click();
await expect(page.getByRole('button', { name: '保存费用上限' })).toBeDisabled();
await page.getByRole('button', { name: '使用与分享', exact: true }).click();
await page.getByRole('button', { name: '使用与接入', exact: true }).click();
await expect(page.getByLabel('应用名称')).toHaveCount(0);
await page.screenshot({ path: testInfo.outputPath('cloud-agent-start-private-use.png') });
await page.getByRole('button', { name: '确认开始使用' }).click();
@@ -288,6 +288,14 @@ test('personal cloud Agent creation, draft save and leave protection in Electron
await expect(page.getByRole('button', { name: '已应用', exact: true })).toBeDisabled();
await expect(page.getByText('修改已保存,尚未应用', { exact: true })).toHaveCount(0);
await app.evaluate(({ BrowserWindow }) => BrowserWindow.getAllWindows()[0].setSize(1366, 768));
await page.getByRole('button', { name: '使用与接入', exact: true }).click();
await expect(page.getByRole('heading', { name: '应用与 API', exact: true })).toBeVisible();
await expect(page.getByRole('button', { name: '打开渠道', exact: true })).toBeVisible();
await expect(page.getByLabel('应用名称')).toBeVisible();
await expect(page.getByRole('heading', { name: '分享给指定用户', exact: true })).toHaveCount(0);
await expect(page.getByLabel('查找分享用户')).toHaveCount(0);
await expect(page.getByRole('button', { name: '复制分享链接', exact: true })).toHaveCount(0);
await page.screenshot({ path: testInfo.outputPath('cloud-agent-access-without-user-sharing.png') });
await page.getByRole('button', { name: '对话', exact: true }).click();
await page.getByRole('region', { name: '智能体对话', exact: true }).getByLabel('消息', { exact: true }).fill('每天早上八点半给我三个创作方向');
await page.getByRole('region', { name: '智能体对话', exact: true }).getByRole('button', { name: '发送', exact: true }).click();