Skip to content

prowgen: allow ci-operator config to skip operator presubmits#5121

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift:mainfrom
Prucek:prowgen-skip-presubmits
Apr 23, 2026
Merged

prowgen: allow ci-operator config to skip operator presubmits#5121
openshift-merge-bot[bot] merged 1 commit into
openshift:mainfrom
Prucek:prowgen-skip-presubmits

Conversation

@Prucek
Copy link
Copy Markdown
Member

@Prucek Prucek commented Apr 22, 2026

Summary

Test plan

  • New test case: "skip operator presubmits via ci-operator config" — fixture is empty {} confirming no operator presubmits generated
  • All existing tests pass (go test ./pkg/prowgen/...)

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added a new configuration option to skip operator presubmits through CI operator configuration overrides, providing additional control over pipeline behavior.
  • Tests

    • Expanded test coverage with new test cases and fixtures validating the operator presubmit skipping functionality.

Add skip_operator_presubmits to the prowgen section of ci-operator
config, so it can be set directly instead of requiring a
.config.prowgen file. This is simpler than the .config.prowgen
approach which requires branch+variant matching, since each
ci-operator config already represents a specific branch and variant.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 22, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: e0331212-b740-40fe-8523-6e229c9f6daa

📥 Commits

Reviewing files that changed from the base of the PR and between 8d45148 and 3db905f.

⛔ Files ignored due to path filters (1)
  • pkg/webreg/zz_generated.ci_operator_reference.go is excluded by !**/zz_generated*
📒 Files selected for processing (4)
  • pkg/api/types.go
  • pkg/prowgen/prowgen.go
  • pkg/prowgen/prowgen_test.go
  • pkg/prowgen/testdata/zz_fixture_TestGenerateJobs_skip_operator_presubmits_via_ci_operator_config.yaml

Walkthrough

This change introduces a new SkipOperatorPresubmits boolean field to the ProwgenOverrides struct, allowing callers to skip operator presubmit generation through CI operator configuration. The job generation logic is updated to respect this flag alongside existing skip presubmits logic, with corresponding test coverage and fixtures added.

Changes

Cohort / File(s) Summary
Type Definitions
pkg/api/types.go
Added new boolean field SkipOperatorPresubmits to ProwgenOverrides struct with JSON tag skip_operator_presubmits,omitempty.
Job Generation Logic
pkg/prowgen/prowgen.go
Modified operator presubmit condition to check both info.Config.SkipPresubmits() and the new configSpec.Prowgen.SkipOperatorPresubmits flag when determining whether to skip operator presubmits.
Test Coverage
pkg/prowgen/prowgen_test.go, pkg/prowgen/testdata/zz_fixture_TestGenerateJobs_skip_operator_presubmits_via_ci_operator_config.yaml
Added table-driven test case verifying operator presubmits are skipped when SkipOperatorPresubmits: true is set in the CI operator configuration, with corresponding empty fixture file.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 11 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (11 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly and clearly describes the main change: introducing the ability to skip operator presubmits via ci-operator configuration.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed This PR uses standard Go table-driven tests, not Ginkgo framework. The test case ID 'skip operator presubmits via ci-operator config' is stable, deterministic, and descriptive, following naming best practices.
Test Structure And Quality ✅ Passed Custom check designed for Ginkgo test code is not applicable to this PR's standard Go testing patterns.
Microshift Test Compatibility ✅ Passed This PR adds only standard Go unit tests to pkg/prowgen/prowgen_test.go using testing.T framework with table-driven patterns, not Ginkgo e2e tests. The custom check for MicroShift test compatibility is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed This pull request does not add any Ginkgo e2e tests. Changes are limited to extending ProwgenOverrides struct, updating Prow job generation logic, adding a unit test case, and adding a test fixture file. The prowgen package generates Prow CI/CD job configurations, not e2e tests.
Topology-Aware Scheduling Compatibility ✅ Passed This pull request modifies Prow job generation configuration logic, not Kubernetes deployment manifests or pod specifications.
Ote Binary Stdout Contract ✅ Passed PR modifies library code to add SkipOperatorPresubmits configuration field with no stdout writes or process-level entry points violating OTE Binary Stdout Contract.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed This PR does not add any Ginkgo e2e tests. It contains only unit tests using Go's standard testing framework in the ci-tools project.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 22, 2026
@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Scheduling tests matching the pipeline_run_if_changed or not excluded by pipeline_skip_if_only_changed parameters:
/test e2e

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Tests from second stage were triggered manually. Pipeline can be controlled only manually, until HEAD changes. Use command to trigger second stage.

1 similar comment
@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Tests from second stage were triggered manually. Pipeline can be controlled only manually, until HEAD changes. Use command to trigger second stage.

@danilo-gemoli
Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Apr 23, 2026
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 23, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: danilo-gemoli, Prucek

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

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [Prucek,danilo-gemoli]

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

@Prucek
Copy link
Copy Markdown
Member Author

Prucek commented Apr 23, 2026

/skip

@Prucek
Copy link
Copy Markdown
Member Author

Prucek commented Apr 23, 2026

/test ci/prow/integration

@Prucek
Copy link
Copy Markdown
Member Author

Prucek commented Apr 23, 2026

/test integration

@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Tests from second stage were triggered manually. Pipeline can be controlled only manually, until HEAD changes. Use command to trigger second stage.

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 23, 2026

@Prucek: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/breaking-changes 3db905f link false /test breaking-changes

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.

@openshift-merge-bot openshift-merge-bot Bot merged commit 37cda1a into openshift:main Apr 23, 2026
17 checks passed
Prucek added a commit to Prucek/release that referenced this pull request Apr 24, 2026
Move enable_secrets_store_csi_driver and skip_operator_presubmits
settings from .config.prowgen files into ci-operator config's prowgen
section.

CSI migration (2 repos):
- openshift/ci-tools
- psalajova/test

skip_operator_presubmits migration (3 repos):
- opendatahub-io/opendatahub-operator (main)
- openshift/csi-operator (4.17-4.20 periodics)
- openshift/gcp-filestore-csi-driver-operator (4.17-4.20 periodics)

Depends on openshift/ci-tools#5120 and openshift/ci-tools#5121.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
openshift-merge-bot Bot pushed a commit to openshift/release that referenced this pull request Apr 24, 2026
…ig (#78232)

Move enable_secrets_store_csi_driver and skip_operator_presubmits
settings from .config.prowgen files into ci-operator config's prowgen
section.

CSI migration (2 repos):
- openshift/ci-tools
- psalajova/test

skip_operator_presubmits migration (3 repos):
- opendatahub-io/opendatahub-operator (main)
- openshift/csi-operator (4.17-4.20 periodics)
- openshift/gcp-filestore-csi-driver-operator (4.17-4.20 periodics)

Depends on openshift/ci-tools#5120 and openshift/ci-tools#5121.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
tbuskey pushed a commit to tbuskey/release that referenced this pull request Apr 24, 2026
…ig (openshift#78232)

Move enable_secrets_store_csi_driver and skip_operator_presubmits
settings from .config.prowgen files into ci-operator config's prowgen
section.

CSI migration (2 repos):
- openshift/ci-tools
- psalajova/test

skip_operator_presubmits migration (3 repos):
- opendatahub-io/opendatahub-operator (main)
- openshift/csi-operator (4.17-4.20 periodics)
- openshift/gcp-filestore-csi-driver-operator (4.17-4.20 periodics)

Depends on openshift/ci-tools#5120 and openshift/ci-tools#5121.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Prucek added a commit to Prucek/release that referenced this pull request Apr 29, 2026
…ig (openshift#78232)

Move enable_secrets_store_csi_driver and skip_operator_presubmits
settings from .config.prowgen files into ci-operator config's prowgen
section.

CSI migration (2 repos):
- openshift/ci-tools
- psalajova/test

skip_operator_presubmits migration (3 repos):
- opendatahub-io/opendatahub-operator (main)
- openshift/csi-operator (4.17-4.20 periodics)
- openshift/gcp-filestore-csi-driver-operator (4.17-4.20 periodics)

Depends on openshift/ci-tools#5120 and openshift/ci-tools#5121.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
BATMAN-JD pushed a commit to BATMAN-JD/release that referenced this pull request May 1, 2026
…ig (openshift#78232)

Move enable_secrets_store_csi_driver and skip_operator_presubmits
settings from .config.prowgen files into ci-operator config's prowgen
section.

CSI migration (2 repos):
- openshift/ci-tools
- psalajova/test

skip_operator_presubmits migration (3 repos):
- opendatahub-io/opendatahub-operator (main)
- openshift/csi-operator (4.17-4.20 periodics)
- openshift/gcp-filestore-csi-driver-operator (4.17-4.20 periodics)

Depends on openshift/ci-tools#5120 and openshift/ci-tools#5121.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
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