Skip to content

Commit 3c4d0bb

Browse files
committedOct 22, 2024··
Fix failing tests
Signed-off-by: Evans Mungai <mbuevans@gmail.com>
1 parent d25b0d9 commit 3c4d0bb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎pkg/registry/utils_test.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ func setup(suite *TestSuite, tlsEnabled, insecure bool) *registry.Registry {
8989
ClientOptWriter(suite.Out),
9090
ClientOptCredentialsFile(credentialsFile),
9191
ClientOptResolver(nil),
92+
ClientOptBasicAuth(testUsername, testPassword),
9293
}
9394

9495
if tlsEnabled {
@@ -128,11 +129,12 @@ func setup(suite *TestSuite, tlsEnabled, insecure bool) *registry.Registry {
128129
// This is required because Docker enforces HTTP if the registry
129130
// host is localhost/127.0.0.1.
130131
suite.DockerRegistryHost = fmt.Sprintf("helm-test-registry:%d", port)
131-
suite.srv, _ = mockdns.NewServer(map[string]mockdns.Zone{
132+
suite.srv, err = mockdns.NewServer(map[string]mockdns.Zone{
132133
"helm-test-registry.": {
133134
A: []string{"127.0.0.1"},
134135
},
135136
}, false)
137+
suite.Nil(err, "no error creating mock DNS server")
136138
suite.srv.PatchNet(net.DefaultResolver)
137139

138140
config.HTTP.Addr = fmt.Sprintf(":%d", port)

0 commit comments

Comments
 (0)
Please sign in to comment.