Improve tests for alerting providers

This commit is contained in:
TwinProduction
2021-02-19 19:06:20 -05:00
parent 9649d80388
commit 50435f4030
8 changed files with 136 additions and 21 deletions

View File

@ -62,7 +62,7 @@ func TestAlertProvider_ToCustomAlertProvider(t *testing.T) {
provider := AlertProvider{URL: "http://example.com"}
customAlertProvider := provider.ToCustomAlertProvider(&core.Service{}, &core.Alert{}, &core.Result{}, true)
if customAlertProvider == nil {
t.Error("customAlertProvider shouldn't have been nil")
t.Fatal("customAlertProvider shouldn't have been nil")
}
if customAlertProvider != customAlertProvider {
t.Error("customAlertProvider should've been equal to customAlertProvider")