diff --git a/cli/command/registry_test.go b/cli/command/registry_test.go index 20bb234db2..6e4dfbbec8 100644 --- a/cli/command/registry_test.go +++ b/cli/command/registry_test.go @@ -185,9 +185,9 @@ func TestRetrieveAuthTokenFromImage(t *testing.T) { imageRef := path.Join(tc.prefix, remoteRef) actual, err := command.RetrieveAuthTokenFromImage(&cfg, imageRef) assert.NilError(t, err) - ac, err := registry.DecodeAuthConfig(actual) + expectedAuthCfg, err := registry.EncodeAuthConfig(tc.expectedAuthCfg) assert.NilError(t, err) - assert.Check(t, is.DeepEqual(*ac, tc.expectedAuthCfg)) + assert.Equal(t, actual, expectedAuthCfg) } }) }