mirror of
https://github.com/TwiN/gatus.git
synced 2026-02-15 11:30:07 +00:00
Start working on #12: Fix inconsistencies in alerting providers
This commit is contained in:
14
alerting/pagerduty_test.go
Normal file
14
alerting/pagerduty_test.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package alerting
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestPagerDutyAlertProvider_IsValid(t *testing.T) {
|
||||
invalidProvider := PagerDutyAlertProvider{IntegrationKey: ""}
|
||||
if invalidProvider.IsValid() {
|
||||
t.Error("provider shouldn't have been valid")
|
||||
}
|
||||
validProvider := PagerDutyAlertProvider{IntegrationKey: "00000000000000000000000000000000"}
|
||||
if !validProvider.IsValid() {
|
||||
t.Error("provider should've been valid")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user