USHIFT-6984: Skip RPM scenario tests when no brew RPMs are available#6707
USHIFT-6984: Skip RPM scenario tests when no brew RPMs are available#6707copejon wants to merge 1 commit into
Conversation
When no brew RPMs exist for the target version (e.g. 5.0 before first release), BREW_LREL_RELEASE_VERSION resolves to empty. Rather than passing that empty value to Robot Framework where it fails all tests, return early from scenario_run_tests() with a warning. Co-authored-by: Cursor <cursoragent@cursor.com>
|
@copejon: This pull request references USHIFT-6984 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 "5.0.0" version, but no target version was set. DetailsIn 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. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (3)
WalkthroughThree related RPM test scenario scripts now add early guards in their test execution functions. Each checks whether ChangesRPM test version availability checks
🎯 1 (Trivial) | ⏱️ ~5 minutes
🚥 Pre-merge checks | ✅ 11 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (11 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: copejon The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
| if [[ -z "${BREW_LREL_RELEASE_VERSION}" ]]; then | ||
| echo "WARNING: No brew RPMs available for ${MAJOR_VERSION}.${MINOR_VERSION}, skipping RPM tests" | ||
| return 0 | ||
| fi |
There was a problem hiding this comment.
@copejon I'll extract this a function into scenario.sh script to follow the same approach as: exit_if_image_not_found() and exit_if_commit_not_found().
Also, I'll add this check in the 3 steps on the scenario: create VM, run tests and remove VM.
Summary
BREW_LREL_RELEASE_VERSIONis emptyTARGET_VERSIONto Robot FrameworkRoot Cause
MicroShift 5.0 has no brew RPMs yet. The version resolution chain (
build_rpms.sh→manage_brew_rpms.sh→common_versions.sh) correctly resolves this to empty — brew RPMs are optional by design (seebuild_rpms.shlines 111-113). The scenario scripts were the only link that didn't handle the empty result, blindly passing it to Robot Framework whereShould Not Be Empty ${TARGET_VERSION}fails and cascades to all tests.Changes
Each RPM scenario's
scenario_run_tests()now checksBREW_LREL_RELEASE_VERSIONat the top and returns 0 with a warning if empty. No other changes needed — the upstream chain already does the authoritative "does this exist" check.Test plan
🤖 Generated with Claude Code
Summary by CodeRabbit