You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
result.AddErrors(fmt.Sprintf("invalid CRD version found for '%s': %s instead of %s", crdName, crdVersion, expectedVersion))
360
+
allVersions:= []string{}
361
+
for_, v:=rangecertCRD.Spec.Versions {
362
+
ifv.Name==expectedVersion {
363
+
ifv.Served {
364
+
clog.V(2).Printf("CRD %s is served with version %s", crdName, v.Name)
365
+
returnnil
366
+
}
367
+
result.AddErrors(fmt.Sprintf("outdated CRD version found for '%s': %s is known but not served", crdName, v.Name))
368
+
returnnil
369
+
}
370
+
allVersions=append(allVersions, v.Name)
341
371
}
342
-
clog.V(2).Printf("CRD %s is installed with version %s", crdName, crdVersion)
372
+
373
+
result.AddErrors(fmt.Sprintf("CRD versions for '%s' are %v, did not find expected version %s or it is not served", crdName, allVersions, expectedVersion))
"Detected cert-manager CRDs with version v0, only versions [v1alpha2 v1alpha3] are fully supported. Certificates for webhooks may not work.",
54
+
"Detected cert-manager CRDs with version v0, only versions [v1 v1beta1 v1alpha3 v1alpha2] are fully supported. Certificates for webhooks may not work.",
assert.EqualValues(t, verifier.NewError("invalid CRD version found for 'issuers.cert-manager.io': v0 instead of v1alpha2"), result)
98
+
assert.EqualValues(t, verifier.NewError("CRD versions for 'issuers.cert-manager.io' are [v0], did not find expected version v1alpha2 or it is not served"), result)
0 commit comments