Skip to content

Conversation

@jiajliu
Copy link
Contributor

@jiajliu jiajliu commented Jan 20, 2026

  1. Revert Revert "OTA-1604: migrate ocp-46922 from otp to cvo repo" #1297 in commit
  2. Fix the issue found in microshift ci test in commit
  • Added handling for NotFound errors when the Infrastructure resource doesn't exist in IsHypershift, to fix the potential issue like microshift failure
  • To be consistent with OTP where cvo cases are not labeled for microshift, added SkipIfMicroshift to skip tests when running on a microshift.

@coderabbitai
Copy link

coderabbitai bot commented Jan 20, 2026

Walkthrough

Adds CVO integration tests and supporting utilities for cluster-type detection and client initialization, plus a new test payload entry for the cluster-version-operator.

Changes

Cohort / File(s) Summary
CVO Test Utilities
test/cvo/util.go
New helper functions: IsHypershift, SkipIfHypershift, IsMicroshift, SkipIfMicroshift, GetRestConfig, GetKubeClient, GetConfigClient. Provide cluster-type detection and client construction with error propagation and test-skip paths.
CVO Integration Tests
test/cvo/cvo.go
New live-cluster tests with BeforeEach loading REST config and Kubernetes client; adds cvoNamespace = "openshift-cluster-version" and tests that the openshift.io/run-level namespace label exists and is empty and that the CVO pod has openshift.io/scc: hostaccess. Skips on HyperShift/MicroShift.
Test Payload Configuration
.openshift-tests-extension/openshift_payload_cluster-version-operator.json
Appended a new test payload entry named [Jira:\"Cluster Version Operator\"] cluster-version-operator should have correct runlevel and scc with labels, resources, source, lifecycle, and environmentSelector fields.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

✨ Finishing touches
  • 📝 Generate docstrings

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 20, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: jiajliu
Once this PR has been reviewed and has the lgtm label, please assign wking for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jiajliu jiajliu changed the title TRT-251 TRT-251:Reapply "OTA-1604: migrate ocp-46922 from otp to cvo repo" Jan 20, 2026
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jan 20, 2026
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jan 20, 2026

@jiajliu: This pull request references TRT-251 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

Instructions 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 openshift-eng/jira-lifecycle-plugin repository.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@test/cvo/cvo.go`:
- Around line 72-82: Update the redundant wording "openshift.io/scc annotation"
to "openshift.io/scc" in the test that inspects the CVO pod: change the
human-readable description string passed to By(...) and the
Expect(...).To(Equal(...)) failure message so they reference "openshift.io/scc"
(use cvoPod.Name and sccAnnotation as already referenced) instead of the
duplicated "annotation" word; ensure the strings around the annotation key are
updated where cvoPod and sccAnnotation are used.

@jiajliu jiajliu changed the title TRT-251:Reapply "OTA-1604: migrate ocp-46922 from otp to cvo repo" TRT-2511:Reapply "OTA-1604: migrate ocp-46922 from otp to cvo repo" Jan 20, 2026
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jan 20, 2026

@jiajliu: This pull request references TRT-2511 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.22.0" version, but no target version was set.

Details

In response to this:

Instructions 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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jan 20, 2026

@jiajliu: This pull request references TRT-2511 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.22.0" version, but no target version was set.

Details

In response to this:

  1. Revert Revert "OTA-1604: migrate ocp-46922 from otp to cvo repo" #1297 in commit
  2. Fix the issue found in microshift ci test in commit
  • Added handling for NotFound errors when the Infrastructure resource doesn't exist in IsHypershift, to fix the potential issue like microshift failure
  • To be consistent with OTP where cvo cases are not labeled for microshift, added SkipIfMicroshift to skip tests when running on a microshift.

Instructions 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 openshift-eng/jira-lifecycle-plugin repository.

@jiajliu
Copy link
Contributor Author

jiajliu commented Jan 20, 2026

/payload-job periodic-ci-openshift-microshift-release-4.22-periodics-e2e-aws-ovn-ocp-conformance

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 20, 2026

@jiajliu: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-microshift-release-4.22-periodics-e2e-aws-ovn-ocp-conformance

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/988df7e0-f5d7-11f0-87ee-a25503e630b6-0

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 20, 2026

@jiajliu: all tests passed!

Full PR test history. Your PR dashboard.

Details

Instructions 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. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants