Files
ssw-mvp/docs/e2e/cases/TC-MNT-005.mjs
T
admin 3247e9fd15 init: ssw-mvp initial commit
- boot/ (Java/Maven, JNPF 7.0) — 移除旧的 boot/.git,源码直接纳入仓库
- web/ (Vue 3 + Vite + Ant Design Vue, pnpm)
- docs/, scard/, nax/
- refs/INDEX.md + refs/国标/(其余 refs/* 开源子仓库不纳入)
- 已忽略: connector_data/, jweb/, log/, web/{dist,node_modules,.pnpm}, boot/*/target/, .DS_Store, .idea, .vscode
2026-08-05 18:29:12 +08:00

35 lines
1.4 KiB
JavaScript

/**
* TC-MNT-005 · 变更不引入缺陷
* Q-MNT 维护性 · 正向 · P0
* 预期:需求变化或修正时,操作流程不引入新的缺陷
*/
export const meta = {
tc: 'TC-MNT-005',
req: 'Q-MNT',
title: '变更不引入缺陷',
type: '正向',
priority: 'P0',
needs: ['be', 'manual']
}
export async function run(t) {
// 自动化部分:在已有连接器上做一次「探测心跳」(轻量变更),前后对比核心数据未破坏
await t.login()
await t.goto('/tds/connectors')
const before = await t.apiList('/api/ssw/tds/Connector')
t.assert(before.length > 0, `当前连接器总数 ${before.length} 条,作为变更前后基线`)
const target = before.find((r) => r.auditStatus === 'PASS') || before[0]
if (target) {
await t.doAction(target.connectorCode, '探测心跳')
await t.expectToast('探测心跳成功')
const after = await t.apiList('/api/ssw/tds/Connector')
t.assert(after.length === before.length, `心跳探测后总数未变(${before.length} → ${after.length}),未引入脏数据`)
} else {
t.skip('无可用连接器,跳过')
}
t.manual([
'人工核对回归:',
'1) 抽取 docs/tdd/B1~B7 报告中的 3 条端到端用例,按 docs/tdd/P1P2_CHAIN_K8S_REPORT.md 中的回退与回放机制跑一遍;',
'2) 断言无新缺陷(绿场景不退化)。'
].join('\n'))
}