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

Merge queue take two #4254

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
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
8 changes: 8 additions & 0 deletions .github/workflows/local-testnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,11 @@ jobs:
- name: Stop local testnet with blinded block production
run: ./stop_local_testnet.sh
working-directory: scripts/local_testnet
local-testnet-success:
name: local-testnet-success
runs-on: ubuntu-latest
needs: ["run-local-testnet"]
michaelsproul marked this conversation as resolved.
Show resolved Hide resolved
steps:
- uses: actions/checkout@v3
- name: Check that success job is dependent on all others
run: ./scripts/ci/check-success-job.sh ./.github/workflows/local-testnet.yml local-testnet-success
39 changes: 38 additions & 1 deletion .github/workflows/test-suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
if: github.event_name == 'pull_request' || github.event_name == 'merge_group'
steps:
- name: Check that the pull request is not targeting the stable branch
run: test ${{ github.base_ref }} != "stable"
run: test "${{ github.base_ref }}" != "stable"
extract-msrv:
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -400,3 +400,40 @@ jobs:
run: rustup override set beta
- name: Run make
run: make
# This job succeeds ONLY IF all others succeed. It is used by the merge queue to determine whether
# a PR is safe to merge. New jobs should be added here.
test-suite-success:
name: test-suite-success
runs-on: ubuntu-latest
needs: [
'target-branch-check',
'extract-msrv',
'cargo-fmt',
'release-tests-ubuntu',
'release-tests-windows',
'beacon-chain-tests',
'op-pool-tests',
'slasher-tests',
'debug-tests-ubuntu',
'state-transition-vectors-ubuntu',
'ef-tests-ubuntu',
'dockerfile-ubuntu',
'eth1-simulator-ubuntu',
'merge-transition-ubuntu',
'no-eth1-simulator-ubuntu',
'syncing-simulator-ubuntu',
'doppelganger-protection-test',
'execution-engine-integration-ubuntu',
'check-benchmarks',
'clippy',
'check-msrv',
'arbitrary-check',
'cargo-audit',
'cargo-vendor',
'cargo-udeps',
'compile-with-beta-compiler'
]
steps:
- uses: actions/checkout@v3
- name: Check that success job is dependent on all others
run: ./scripts/ci/check-success-job.sh ./.github/workflows/test-suite.yml test-suite-success
michaelsproul marked this conversation as resolved.
Show resolved Hide resolved
13 changes: 13 additions & 0 deletions scripts/ci/check-success-job.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash
# Check that $SUCCESS_JOB depends on all other jobs in the given $YAML

set -euf -o pipefail

YAML=$1
SUCCESS_JOB=$2

yq '... comments="" | .jobs | map(. | key) | .[]' < "$YAML" | grep -v "$SUCCESS_JOB" | sort > all_jobs.txt
yq "... comments=\"\" | .jobs.$SUCCESS_JOB.needs[]" < "$YAML" | grep -v "$SUCCESS_JOB" | sort > dep_jobs.txt
michaelsproul marked this conversation as resolved.
Show resolved Hide resolved
diff all_jobs.txt dep_jobs.txt || (echo "COMPLETENESS CHECK FAILED" && exit 1)
rm all_jobs.txt dep_jobs.txt
echo "COMPLETENESS CHECK PASSED"