diff --git a/internal/operator-controller/applier/helm.go b/internal/operator-controller/applier/helm.go index 99d937308..7691989e6 100644 --- a/internal/operator-controller/applier/helm.go +++ b/internal/operator-controller/applier/helm.go @@ -103,12 +103,14 @@ func (h *Helm) runPreAuthorizationChecks(ctx context.Context, ext *ocv1.ClusterE } } slices.Sort(missingRuleDescriptions) + // This phrase is explicitly checked by external testing preAuthErrors = append(preAuthErrors, fmt.Errorf("service account requires the following permissions to manage cluster extension:\n %s", strings.Join(missingRuleDescriptions, "\n "))) } if authErr != nil { preAuthErrors = append(preAuthErrors, fmt.Errorf("authorization evaluation error: %w", authErr)) } if len(preAuthErrors) > 0 { + // This phrase is explicitly checked by external testing return fmt.Errorf("pre-authorization failed: %v", errors.Join(preAuthErrors...)) } return nil