From 6c77ff0a2ce84a58ea533a1f433401cbd2d1ee55 Mon Sep 17 00:00:00 2001 From: Cameron Moore Date: Wed, 18 Sep 2019 16:59:11 -0500 Subject: [PATCH 1/2] Fix TestWebhook tests PR #266 appears to have changed the default response code to StatusOK. waitForServerReady() was expected a StatusNotFound response, which was preventing all TestWebhook tests from running. --- webhook_test.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/webhook_test.go b/webhook_test.go index 6113b9b..a1f8fc4 100644 --- a/webhook_test.go +++ b/webhook_test.go @@ -76,7 +76,6 @@ func TestWebhook(t *testing.T) { for _, tt := range hookHandlerTests { t.Run(tt.desc, func(t *testing.T) { - ip, port := serverAddress(t) args := []string{fmt.Sprintf("-hooks=%s", configPath), fmt.Sprintf("-ip=%s", ip), fmt.Sprintf("-port=%s", port), "-verbose"} @@ -249,7 +248,7 @@ func serverAddress(t *testing.T) (string, string) { func waitForServerReady(t *testing.T, ip, port string) { waitForServer(t, fmt.Sprintf("http://%v:%v/", ip, port), - http.StatusNotFound, + http.StatusOK, 5*time.Second) } From 74e55e3089fd42d1ee774f83f54757ba0aeb1bdc Mon Sep 17 00:00:00 2001 From: Cameron Moore Date: Wed, 18 Sep 2019 17:00:22 -0500 Subject: [PATCH 2/2] Update go versions in Travis CI Test against the latest three minor releases. --- .travis.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index ef89aae..518627a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,9 @@ language: go go: - - 1.8.x - - 1.9.x + - 1.11.x + - 1.12.x + - 1.13.x - tip os: