fix rebase artifacts

fix/snakeswap
nils måsén 3 years ago committed by nils måsén
parent 909c90a558
commit 385357bab5

@ -82,7 +82,7 @@ func testGetSecretsFromFiles(t *testing.T, flagName string, expected string) {
func TestHTTPAPIPeriodicPollsFlag(t *testing.T) {
cmd := new(cobra.Command)
SetDefaults()
RegisterDockerFlags(cmd)
RegisterSystemFlags(cmd)

@ -101,12 +101,12 @@ var _ = Describe("notifications", func() {
When("passing a discord url to the slack notifier", func() {
command := cmd.NewRootCommand()
flags.RegisterNotificationFlags(command)
flags.RegisterNotificationFlags()
channel := "123456789"
token := "abvsihdbau"
color := notifications.ColorInt
hostname := notifications.GetHostname(command)
hostname := notifications.GetHostname()
title := url.QueryEscape(notifications.GetTitle(hostname))
expected := fmt.Sprintf("discord://%s@%s?color=0x%x&colordebug=0x0&colorerror=0x0&colorinfo=0x0&colorwarn=0x0&title=%s&username=watchtower", token, channel, color, title)
buildArgs := func(url string) []string {
@ -190,11 +190,11 @@ var _ = Describe("notifications", func() {
When("converting a gotify service config into a shoutrrr url", func() {
It("should return the expected URL", func() {
command := cmd.NewRootCommand()
flags.RegisterNotificationFlags(command)
flags.RegisterNotificationFlags()
token := "aaa"
host := "shoutrrr.local"
hostname := notifications.GetHostname(command)
hostname := notifications.GetHostname()
title := url.QueryEscape(notifications.GetTitle(hostname))
expectedOutput := fmt.Sprintf("gotify://%s/%s?title=%s", host, token, title)

Loading…
Cancel
Save