mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-26 14:46:42 +00:00
.github/workflows: run more parallel CI jobs (#976)
* .github/workflows: run parallel CI jobs * undo
This commit is contained in:
parent
4d96b145e4
commit
530a2331bf
1 changed files with 101 additions and 16 deletions
117
.github/workflows/ci.yml
vendored
117
.github/workflows/ci.yml
vendored
|
|
@ -15,7 +15,39 @@ concurrency:
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
build:
|
||||||
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ ubuntu-20.04 ] # list of os: https://github.com/actions/virtual-environments
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- run: |
|
||||||
|
git submodule update --init --recursive --force
|
||||||
|
git fetch --no-tags --prune --depth=1 origin +refs/heads/master:refs/remotes/origin/master
|
||||||
|
|
||||||
|
- uses: actions/setup-go@v3
|
||||||
|
with:
|
||||||
|
go-version: 1.20.x
|
||||||
|
|
||||||
|
- name: Install dependencies on Linux
|
||||||
|
if: runner.os == 'Linux'
|
||||||
|
run: sudo apt update && sudo apt install build-essential
|
||||||
|
|
||||||
|
- uses: actions/cache@v3
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cache/go-build
|
||||||
|
~/Library/Caches/go-build
|
||||||
|
~/go/pkg/mod
|
||||||
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
|
restore-keys: ${{ runner.os }}-go-
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
run: make all
|
||||||
|
|
||||||
|
lint:
|
||||||
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
|
|
@ -39,6 +71,30 @@ jobs:
|
||||||
if: runner.os == 'Linux'
|
if: runner.os == 'Linux'
|
||||||
run: make lintci-deps
|
run: make lintci-deps
|
||||||
|
|
||||||
|
- name: Lint
|
||||||
|
if: runner.os == 'Linux'
|
||||||
|
run: make lint
|
||||||
|
|
||||||
|
unit-tests:
|
||||||
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ ubuntu-20.04 ] # list of os: https://github.com/actions/virtual-environments
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- run: |
|
||||||
|
git submodule update --init --recursive --force
|
||||||
|
git fetch --no-tags --prune --depth=1 origin +refs/heads/master:refs/remotes/origin/master
|
||||||
|
|
||||||
|
- uses: actions/setup-go@v3
|
||||||
|
with:
|
||||||
|
go-version: 1.20.x
|
||||||
|
|
||||||
|
- name: Install dependencies on Linux
|
||||||
|
if: runner.os == 'Linux'
|
||||||
|
run: sudo apt update && sudo apt install build-essential
|
||||||
|
|
||||||
- uses: actions/cache@v3
|
- uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: |
|
path: |
|
||||||
|
|
@ -48,27 +104,12 @@ jobs:
|
||||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: ${{ runner.os }}-go-
|
restore-keys: ${{ runner.os }}-go-
|
||||||
|
|
||||||
- name: Build
|
|
||||||
run: make all
|
|
||||||
|
|
||||||
- name: Lint
|
|
||||||
if: runner.os == 'Linux'
|
|
||||||
run: make lint
|
|
||||||
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: make test
|
run: make test
|
||||||
|
|
||||||
#- name: Data race tests
|
#- name: Data race tests
|
||||||
# run: make test-race
|
# run: make test-race
|
||||||
|
|
||||||
- name: test-integration
|
|
||||||
run: make test-integration
|
|
||||||
|
|
||||||
- name: Upload coverage to Codecov
|
|
||||||
uses: codecov/codecov-action@v1
|
|
||||||
with:
|
|
||||||
file: ./cover.out
|
|
||||||
|
|
||||||
# # TODO: make it work
|
# # TODO: make it work
|
||||||
# - name: Reproducible build test
|
# - name: Reproducible build test
|
||||||
# run: |
|
# run: |
|
||||||
|
|
@ -81,6 +122,50 @@ jobs:
|
||||||
# fi
|
# fi
|
||||||
|
|
||||||
integration-tests:
|
integration-tests:
|
||||||
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ ubuntu-20.04 ] # list of os: https://github.com/actions/virtual-environments
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- run: |
|
||||||
|
git submodule update --init --recursive --force
|
||||||
|
git fetch --no-tags --prune --depth=1 origin +refs/heads/master:refs/remotes/origin/master
|
||||||
|
|
||||||
|
- uses: actions/setup-go@v3
|
||||||
|
with:
|
||||||
|
go-version: 1.20.x
|
||||||
|
|
||||||
|
- name: Install dependencies on Linux
|
||||||
|
if: runner.os == 'Linux'
|
||||||
|
run: sudo apt update && sudo apt install build-essential
|
||||||
|
|
||||||
|
- uses: actions/cache@v3
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cache/go-build
|
||||||
|
~/Library/Caches/go-build
|
||||||
|
~/go/pkg/mod
|
||||||
|
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||||
|
restore-keys: ${{ runner.os }}-go-
|
||||||
|
|
||||||
|
- name: test-integration
|
||||||
|
run: make test-integration
|
||||||
|
|
||||||
|
codecov:
|
||||||
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ ubuntu-20.04 ] # list of os: https://github.com/actions/virtual-environments
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
steps:
|
||||||
|
- name: Upload coverage to Codecov
|
||||||
|
uses: codecov/codecov-action@v1
|
||||||
|
with:
|
||||||
|
file: ./cover.out
|
||||||
|
|
||||||
|
matic-cli-tests:
|
||||||
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
if: (github.event.action != 'closed' || github.event.pull_request.merged == true)
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue