[release-1.31] test: skip TLS profile e2e tests when APIServer is not writable - #2317
Conversation
The TLS profile tests update the cluster-scoped APIServer resource, which managed clusters (e.g. ROSA/OSD) reject via Red Hat SRE admission webhooks with a Forbidden error. Instead of enumerating cluster types, the tls-profile BeforeAll now probes writability directly with a no-op server-side dry-run update and skips on Forbidden, persisting nothing. This generalises the existing hosted-cluster guard and covers any cluster where the resource is not manageable, while self-managed OpenShift continues to run the tests. Signed-off-by: Mikhail Abramov <mabramov@redhat.com>
|
Hi @unsortedhashsets. Thanks for your PR. I'm waiting for a istio-ecosystem or istio member to verify that this patch is reasonable to test. If it is, they should reply with Tip We noticed you've done this a few times! Consider joining the org to skip this step and gain Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
/ok-to-test |
PR for release-1.31
What type of PR is this?
What this PR does / why we need it:
Backport of #2313 to
release-1.31.The TLS profile tests update the cluster-scoped APIServer resource, which managed clusters (e.g. ROSA/OSD) reject via Red Hat SRE admission webhooks with a Forbidden error. Instead of enumerating cluster types, the tls-profile BeforeAll now probes writability directly with a no-op server-side dry-run update and skips on Forbidden, persisting nothing. This generalises the existing hosted-cluster guard and covers any cluster where the resource is not manageable, while self-managed OpenShift continues to run the tests.
Which issue(s) this PR fixes:
Fixes #
Related Issue/PR #2313
Additional information:
Cherry-picked commit:
5f5bc8fc— test: skip TLS profile e2e tests when APIServer is not writable (test: skip TLS profile e2e tests when APIServer is not writable #2313)The hosted-cluster guard (#1873) is already present on
release-1.31, so the probe slots in after it with no conflicts.Verified: e2e test package compiles (
go test -tags e2e -c ./tests/e2e/operator/); no conflicts.