fix: update unit test for go 1.14 error string change (#7835)

* fix: update unit test for go 1.14 error string change

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>

* changed strategy based on conversation with Adam

Signed-off-by: Matt Butcher <matt.butcher@microsoft.com>
pull/7831/head
Matt Butcher 5 years ago committed by GitHub
parent 97c68adc4d
commit 3706aa7ca6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -308,7 +308,7 @@ func TestErrorFindChartInRepoURL(t *testing.T) {
if _, err := FindChartInRepoURL("http://someserver/something", "nginx", "", "", "", "", g); err == nil {
t.Errorf("Expected error for bad chart URL, but did not get any errors")
} else if !strings.Contains(err.Error(), `looks like "http://someserver/something" is not a valid chart repository or cannot be reached: Get http://someserver/something/index.yaml`) {
} else if !strings.Contains(err.Error(), `looks like "http://someserver/something" is not a valid chart repository or cannot be reached`) {
t.Errorf("Expected error for bad chart URL, but got a different error (%v)", err)
}

Loading…
Cancel
Save