Skip to content

Commit

Permalink
Address linter complaints
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Weaver <[email protected]>
  • Loading branch information
alexweav committed Oct 9, 2023
1 parent 6695f7d commit 12a3d16
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
4 changes: 0 additions & 4 deletions cmd/alertmanager/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ import (
"github.com/stretchr/testify/require"
)

type sendResolved bool

func (s sendResolved) SendResolved() bool { return bool(s) }

func TestExternalURL(t *testing.T) {
hostname := "foo"
for _, tc := range []struct {
Expand Down
5 changes: 3 additions & 2 deletions notify/receiver/receiver.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ package receiver
import (
"github.com/go-kit/log"

commoncfg "github.com/prometheus/common/config"

"github.com/prometheus/alertmanager/config"
"github.com/prometheus/alertmanager/notify"
"github.com/prometheus/alertmanager/notify/discord"
Expand All @@ -33,12 +35,11 @@ import (
"github.com/prometheus/alertmanager/notify/wechat"
"github.com/prometheus/alertmanager/template"
"github.com/prometheus/alertmanager/types"
commoncfg "github.com/prometheus/common/config"
)

type Wrapper func(string, notify.Notifier) notify.Notifier

var NoWrap Wrapper = nil
var NoWrap Wrapper

// BuildReceiverIntegrations builds a list of integration notifiers off of a
// receiver config.
Expand Down
2 changes: 1 addition & 1 deletion notify/receiver/receiver_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func TestBuildReceiverIntegrations(t *testing.T) {
t.Run("invokes notifier wrapper func", func(t *testing.T) {
calls := 0
wrap := func(_ string, n notify.Notifier) notify.Notifier {
calls += 1
calls++
return n
}
cfg := config.Receiver{
Expand Down

0 comments on commit 12a3d16

Please sign in to comment.