feat: integrate OA activation workflows and business migration
This commit is contained in:
@@ -41,7 +41,7 @@ func exerciseAlertOwnerRecheck(t *testing.T, db *gorm.DB) {
|
||||
}
|
||||
write(true)
|
||||
oldExemption := &business.AlertExemption{ChannelKey: business.ChannelKey{SourceDB: "lx", ID: 1}, OwnerID: 7, AddedBy: 7, AddedName: "原商务", Reason: "原商务的豁免", AddedAt: now}
|
||||
if err := NewAlertGovernanceRepo(testData{db}).AddExemption(ctx, scope, oldExemption.ChannelKey, func(*business.AlertExemptionTarget) (*business.AlertExemption, error) { return oldExemption, nil }); err != nil {
|
||||
if err := NewAlertGovernanceRepo(testData{db}, activationDatabases{db}).AddExemption(ctx, scope, oldExemption.ChannelKey, func(*business.AlertExemptionTarget) (*business.AlertExemption, error) { return oldExemption, nil }); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@ func exerciseAlertOwnerRecheck(t *testing.T, db *gorm.DB) {
|
||||
if len(histories) != 2 || histories[0].BusinessID != 7 || histories[0].AlertContent != "换绑前" || histories[1].BusinessID != 8 {
|
||||
t.Fatalf("旧商务预警不应被转移给新商务: %+v", histories)
|
||||
}
|
||||
governance := NewAlertGovernanceRepo(testData{db})
|
||||
governance := NewAlertGovernanceRepo(testData{db}, activationDatabases{db})
|
||||
called := false
|
||||
build := func(*business.AlertExemptionTarget) (*business.AlertExemption, error) {
|
||||
called = true
|
||||
|
||||
Reference in New Issue
Block a user