mirror of
https://github.com/ThearchyHelios/AgentLab.git
synced 2026-11-15 05:21:57 +00:00
数据目录 F2b:目录页的修改时间、单项弹层的更新时间改用全站统一的短格式(formatTime:今天「10:05」、今年「9/28 10:00」),完整的带秒带时区的时间放进悬停;补检查脚本的断言
This commit is contained in:
@@ -802,6 +802,10 @@ await section('数据目录 · 表详情与单项审阅', async () => {
|
||||
await openDetail(page, S1, 'visits')
|
||||
const head = await detail(page).locator('header').innerText()
|
||||
check('表头:中文名、表类型、表名、使用次数、谁改过', ['入园记录', '明细表', 'visits', '使用 42 次', '审核甲'].every((s) => head.includes(s)), head.replace(/\s+/g, ' '))
|
||||
// 时间用全站统一的短格式(formatTime:今年写「9/28 10:00」),完整时间(带秒和时区)放在悬停里
|
||||
const updated = detail(page).locator('[data-detail-updated]')
|
||||
check('……修改时间写全站统一的短格式,完整时间放在悬停里', /^审核甲 于 (2026\/)?9\/28 10:00 修改$/.test(await updated.innerText())
|
||||
&& !head.includes('UTC') && (await updated.getAttribute('title')) === '2026-09-28 10:00:00 (UTC+08:00)', `${await updated.innerText()} / ${await updated.getAttribute('title')}`)
|
||||
const grain = page.locator('[data-field="grain"]')
|
||||
check('表级项:粒度的值和「推断 · 模型起草」', (await grain.innerText()).includes('一张门票的一次入园') && (await grain.innerText()).includes('推断')
|
||||
&& (await grain.innerText()).includes('模型起草'))
|
||||
@@ -826,6 +830,8 @@ await section('数据目录 · 表详情与单项审阅', async () => {
|
||||
await openMark(page, 'grain')
|
||||
const pt = await panel(page).innerText()
|
||||
check('点状态标识:弹层写位置、状态说明、来源', pt.includes('表的粒度的来源和状态') && pt.includes('只作提示,确认后才参与 SQL 检查') && pt.includes('来源:模型起草'), pt.replace(/\s+/g, ' '))
|
||||
check('……更新时间也写短格式,完整时间放在悬停里', /更新于 (2026\/)?9\/28 10:00/.test(pt) && !pt.includes('UTC')
|
||||
&& (await panel(page).locator('[data-item-updated]').getAttribute('title')) === '2026-09-28 10:00:00 (UTC+08:00)', pt.replace(/\s+/g, ' '))
|
||||
check('……焦点落在「确认」上', await page.evaluate(() => document.activeElement?.getAttribute('data-review-action')) === 'confirm')
|
||||
check('……推断项已是初始状态,「恢复」不可点', await panel(page).locator('[data-review-action="reset"]').isDisabled())
|
||||
await page.keyboard.press('Escape')
|
||||
|
||||
Reference in New Issue
Block a user