mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-10-24 04:33:17 +00:00
Match quiet-hours diagnosis regression to its category reason
Keep the new clock/dispatch proof aligned with the unchanged quiet_hours:non-critical diagnosis contract; no production or schedule policy changes. Change-source: pulse-maintainer
This commit is contained in:
@@ -564,7 +564,7 @@ func TestQuietHoursClockDispatchAndDiagnosis(t *testing.T) {
|
||||
}
|
||||
if deferred {
|
||||
want, _ := time.Parse(time.RFC3339, tc.replay)
|
||||
if diagnosis.Status != AlertDeliveryStatusDeferred || diagnosis.Reason != AlertDeliveryReasonQuietHours || diagnosis.QuietHoursReplayAt == nil || !diagnosis.QuietHoursReplayAt.Equal(want) {
|
||||
if diagnosis.Status != AlertDeliveryStatusDeferred || diagnosis.Reason != AlertDeliveryReasonQuietHours+":non-critical" || diagnosis.QuietHoursReplayAt == nil || !diagnosis.QuietHoursReplayAt.Equal(want) {
|
||||
t.Fatalf("diagnosis disagrees with local-clock policy: %+v", diagnosis)
|
||||
}
|
||||
} else if diagnosis.Status != AlertDeliveryStatusWouldSend || diagnosis.Reason != AlertDeliveryReasonReady {
|
||||
|
||||
Reference in New Issue
Block a user