Page the live catalog to an editable permission before editing
Why: the real catalog leads with protected system actions whose checkboxes are disabled; the live flow must advance permission groups to reach an editable action. Evidence: deterministic 16/16 unchanged. Impact: live test navigation only. Refs: feature/iam-u4-role-permission-ui
This commit is contained in:
@@ -585,7 +585,12 @@ test('LIVE 真实登录加载真实权限目录,创建、配置并停用角色
|
||||
await page.getByLabel('新角色描述').fill('活体验收职位')
|
||||
await page.getByRole('button', { name: '创建角色', exact: true }).click()
|
||||
await expect(page.getByRole('status')).toContainText('已创建角色 数据工程师', { timeout: 15_000 })
|
||||
// 真实目录的首页可能全是受保护系统授权(复选框禁用):逐组翻到可编辑动作。
|
||||
const firstDefault = page.locator('input[aria-label$="默认允许"]:not([disabled])').first()
|
||||
for (let pageIdx = 0; (await firstDefault.count()) === 0 && pageIdx < 15; pageIdx++) {
|
||||
await page.getByRole('button', { name: '下一组', exact: true }).click()
|
||||
await page.waitForTimeout(150)
|
||||
}
|
||||
await expect(firstDefault).toBeVisible({ timeout: 15_000 })
|
||||
await firstDefault.check()
|
||||
await page.getByRole('button', { name: '保存权限', exact: true }).click()
|
||||
|
||||
Reference in New Issue
Block a user