openshift / openshift/rosa

Add a helper to select an available channel for an OpenShift version

Open
#3,474 0 comments 0 reactions 1 assignee View on GitHub

@amandahla is already working on this.

Since Aug 18, 2026.

Dominant language
Go
Stars
103
Forks
257
Avg merge
2d 21h
Merged PRs (30d)
43

Description

Summary

Add a reusable test helper that takes an OpenShift version identifier and obtains the version's availableChannels from the OCM endpoint:

/api/clusters_mgmt/v1/versions/{version id}

Use the helper where E2E tests need a channel for a selected version.

Rationale

Tests must not hard-code a channel such as eus-4.16. The channels available for a version can change. The helper must derive a valid channel from the current OCM version metadata.

The current test can omit --channel. This follow-up provides the reusable helper for tests that must explicitly select a channel.

Affected area

  • tests/e2e/test_rosacli_cluster.go
  • Test utilities that access OCM version metadata

Acceptance criteria

  • The helper accepts an OpenShift version identifier.
  • The helper queries /api/clusters_mgmt/v1/versions/{version id}.
  • The helper returns channel data from availableChannels.
  • The helper handles missing or empty availableChannels with a clear error.
  • E2E tests that require an explicit channel use the helper instead of a hard-coded channel value.
  • Add focused test coverage for the helper.

References

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.