Skip to content

Conversation

@tmshort
Copy link
Contributor

@tmshort tmshort commented Oct 30, 2025

Consolidates experimental-e2e tests into the main e2e test suite and implements automatic feature-gate detection from OLM deployments.

Changes:

  • Merges experimental-e2e tests into test/e2e directory
  • Adds new feature_gates.go helper that queries OLM deployments to detect enabled/disabled feature gates
  • Updates tests to skip automatically when required feature gates are disabled (SingleOwnNamespaceInstallSupport, WebhookProviderCertManager)
  • Removes separate experimental-e2e Makefile target
  • Falls back to programmatic defaults when feature gates aren't explicitly configured

This allows the test suite to adapt to different cluster configurations without manual test selection.

Post-commit improvements (with AI assistance):

  • Fixed typo: processFeatuteGate -> processFeatureGate
  • Added sync.Once for thread-safe feature gate caching
  • Improved error messages for feature gate validation
  • Added package and function documentation

Assisted-by: Claude code

Description

Reviewer Checklist

  • API Go Documentation
  • Tests: Unit Tests (and E2E Tests, if appropriate)
  • Comprehensive Commit Messages
  • Links to related GitHub Issue(s)

Consolidates experimental-e2e tests into the main e2e test suite
and implements automatic feature-gate detection from OLM deployments.

Changes:
- Merges experimental-e2e tests into test/e2e directory
- Adds new feature_gates.go helper that queries OLM deployments
  to detect enabled/disabled feature gates
- Updates tests to skip automatically when required feature gates
  are disabled (SingleOwnNamespaceInstallSupport,
  WebhookProviderCertManager)
- Removes separate experimental-e2e Makefile target
- Falls back to programmatic defaults when feature gates aren't
  explicitly configured

This allows the test suite to adapt to different cluster
configurations without manual test selection.

Post-commit improvements (with AI assistance):
- Fixed typo: processFeatuteGate -> processFeatureGate
- Added sync.Once for thread-safe feature gate caching
- Improved error messages for feature gate validation
- Added package and function documentation

Signed-off-by: Todd Short <tshort@redhat.com>
Assisted-by: Claude code
@tmshort tmshort requested a review from a team as a code owner October 30, 2025 19:54
@netlify
Copy link

netlify bot commented Oct 30, 2025

Deploy Preview for olmv1 ready!

Name Link
🔨 Latest commit 5b291aa
🔍 Latest deploy log https://app.netlify.com/projects/olmv1/deploys/6903c283bef54700082dbb37
😎 Deploy Preview https://deploy-preview-2293--olmv1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@tmshort tmshort changed the title ✨ Refactor e2e tests to support feature-gate aware skipping ✨ OPRUN-4232: Refactor e2e tests to support feature-gate aware skipping Oct 30, 2025
@tmshort tmshort requested review from perdasilva and removed request for bentito October 30, 2025 19:56
@codecov
Copy link

codecov bot commented Oct 30, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 71.25%. Comparing base (760855f) to head (5b291aa).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2293      +/-   ##
==========================================
- Coverage   71.28%   71.25%   -0.03%     
==========================================
  Files          90       90              
  Lines        7003     7003              
==========================================
- Hits         4992     4990       -2     
- Misses       1599     1600       +1     
- Partials      412      413       +1     
Flag Coverage Δ
e2e 45.85% <ø> (-0.08%) ⬇️
experimental-e2e 14.70% <ø> (+0.11%) ⬆️
unit 58.87% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@oceanc80 oceanc80 left a comment

Choose a reason for hiding this comment

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

/lgtm

}
}

func gatherFeatureGates(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: I would reorder these functions so they are in the order they're used so a human reading the code doesn't have to scroll to the bottom and then work their way back up.

Current order:

  • processFeatureGate
  • gatherFeatureGatesFromDeployment
  • gatherFeatureGates

Suggested Order:

  • gatherFeatureGates
  • gatherFeatureGatesFromDeployment
  • processFeatureGate

Copy link
Contributor Author

Choose a reason for hiding this comment

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

But you can tell I'm a C programmer this way!
(But yeah, I hear you)

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 31, 2025
@tmshort
Copy link
Contributor Author

tmshort commented Oct 31, 2025

/approve

@openshift-ci
Copy link

openshift-ci bot commented Oct 31, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: tmshort

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

The pull request process is described here

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 31, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 8bda126 into operator-framework:main Oct 31, 2025
29 of 30 checks passed
@tmshort tmshort deleted the rm-experimental-e2e branch October 31, 2025 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants