实现七月迭代公共技术基础
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 9m20s

This commit is contained in:
2026-07-23 17:52:48 +09:00
parent f7c42252c0
commit 17782d5f8e
76 changed files with 5246 additions and 158 deletions

View File

@@ -0,0 +1,20 @@
package releasegate
import "testing"
func TestReportBlocksOnlyOnBlockingFindings(t *testing.T) {
t.Parallel()
report := Report{Phase: PhasePre, Findings: []Finding{{
Code: "FOUNDATION_OBJECT_MISSING", Severity: SeverityInfo, Object: "tb_outbox_event",
}}}
if !report.Passed() {
t.Fatal("迁移前公共对象尚未创建不应单独阻断发布")
}
report.Findings = append(report.Findings, Finding{
Code: "OUTBOX_UNDELIVERED", Severity: SeverityBlock, Object: "tb_outbox_event", Count: 1,
})
if report.Passed() {
t.Fatal("存在未投递事件时必须阻断发布")
}
}