788857d2c3
remove unneeded panics improve error handling add tests fix error checking that was comparing for exact values sort imports
15 lines
253 B
Go
15 lines
253 B
Go
package util
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
)
|
|
|
|
func TestSendToSlack(t *testing.T) {
|
|
slackToken := os.Getenv("SLACK_TOKEN")
|
|
if slackToken == "" {
|
|
t.Error("A slack token was not provided")
|
|
}
|
|
InitSlack(slackToken)
|
|
SendToSlackInfo("This is a test :)")
|
|
}
|