Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable merge queue #177

Merged
merged 3 commits into from
Feb 4, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,31 @@ on:
pull_request:
branches: [ '*' ]

merge_group:
types: [ checks_requested ]

workflow_dispatch:

schedule:
- cron: "15 1 * * *"

jobs:
pre-job:
runs-on: ubuntu-latest
name: Pre job checks
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- uses: actions/checkout@v4
- id: skip_check
uses: fkirc/[email protected]
with:
cancel_others: false
paths_ignore: '["**/*.md", "**/*.adoc", "LICENSE"]'
unit-tests:
name: Unit Tests
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
defaults:
run:
Expand All @@ -36,6 +55,8 @@ jobs:
verbose: true
integration-tests:
name: Integration Tests
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
defaults:
run:
Expand Down Expand Up @@ -70,6 +91,8 @@ jobs:
verbose: true
verify-manifests:
name: Verify manifests
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -82,6 +105,8 @@ jobs:
run: make verify-manifests
verify-bundle:
name: Verify bundle
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -96,6 +121,8 @@ jobs:
make verify-bundle
verify-fmt:
name: Verify fmt
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -110,6 +137,8 @@ jobs:
make verify-fmt
verify-tidy:
name: Verify tidy
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -127,6 +156,8 @@ jobs:
make verify-tidy
lint:
name: Lint
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -140,6 +171,8 @@ jobs:
run: make run-lint
verify-generate:
name: Verify generate
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -154,6 +187,8 @@ jobs:
make verify-generate
verify-go-mod:
name: Verify go.mod
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.21.x
Expand All @@ -168,6 +203,8 @@ jobs:
make verify-go-mod
verify-helm-charts:
name: Verify helm charts
if: ${{ github.event_name == 'schedule' || needs.pre-job.outputs.should_skip != 'true' }}
needs: pre-job
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.22.x
Expand All @@ -180,3 +217,14 @@ jobs:
- name: Run make verify-helm-charts
run: |
make verify-helm-charts
required-checks:
name: Tests Required Checks
# This check adds a list of checks to one job to simplify adding settings to the repo.
# If a new check is added in this file, and it should be retested on entry to the merge queue,
# it needs to be added to the list below aka needs: [ existing check 1, existing check 2, new check ].
needs: [ unit-tests, integration-tests, verify-manifests, verify-bundle, verify-fmt, verify-tidy, lint, verify-generate, verify-go-mod, verify-helm-charts ]
if: always()
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: echo '${{ toJSON(needs) }}' | jq -e 'all(.[]; .result == "success" or .result == "skipped")'
Loading