Pick a section node for the forensic path

Why: the first docs-tree node is document-level and carries no event history; U4 evidence-finding targets sections.

Evidence: scripts/e2e.sh rerun in this task.

Impact: test-only.
This commit is contained in:
2026-10-11 17:54:25 +00:00
parent fb846bed14
commit d2d81e119c
+5 -2
View File
@@ -67,9 +67,12 @@ test.describe.serial('U4 项目追溯审计工作区', () => {
await login(page)
await openAudit(page)
// 路径①:资料与文档(点击1)→ 选章节(点击2)→ 对象详情含最近事件(修改原因)。
// 树首个节点是文档级(无事件史),取证对象选 section。
await page.getByRole('tab', { name: '资料与文档' }).click()
await expect(page.locator('.rdm-audit-tree-node')).not.toHaveCount(0)
await page.locator('.rdm-audit-tree-node').first().click()
const sectionNode = page.locator('.rdm-audit-tree-node')
.filter({ has: page.locator('.rdm-audit-tree-kind', { hasText: 'section' }) }).first()
await expect(sectionNode).toBeVisible()
await sectionNode.click()
await expect(page.locator('.rdm-audit-detail')).toBeVisible()
await expect(page.getByText('最近事件')).toBeVisible()
// 路径②:关联追溯(点击1)→ 选章节(点击2)→ 来源依据/影响对象分列。