-
Notifications
You must be signed in to change notification settings - Fork 27
83 lines (79 loc) · 2.6 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: ci
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} # add concurrency
cancel-in-progress: true
jobs:
ci:
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
ci_step: [
"lint",
"test",
"test-fuzz",
"integration tests coreum-modules",
"integration tests coreum-stress",
"integration tests coreum-ibc",
"integration tests coreum-upgrade-v4.0.0",
]
include:
- ci_step: "lint"
command: make lint
codecov: false
- ci_step: "test"
command: make test
codecov: true
codecov-name: coreum
- ci_step: "test-fuzz"
command: make test-fuzz
codecov: false
- ci_step: "integration tests coreum-modules"
command: make integration-tests-modules
codecov: true
codecov-name: coreum-integration-tests-modules
- ci_step: "integration tests coreum-stress"
command: make integration-tests-stress
codecov: false
- ci_step: "integration tests coreum-ibc"
command: make integration-tests-ibc
codecov: false
- ci_step: "integration tests coreum-upgrade-v4.0.0"
command: make integration-tests-upgrade
codecov: false
runs-on: self-hosted
steps:
- name: Go version used to build builder
run: go version
- name: Checkout coreum
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Authenticate to Google Cloud
uses: google-github-actions/auth@v0
with:
credentials_json: '${{ secrets.GOOGLE_CREDENTIALS }}'
- name: Download cache from bucket
run: gsutil rsync -r gs://coreum-ci-cache /root/.cache/
- name: Run ${{ matrix.ci_step }}
run: ${{ matrix.command }}
- name: Upload cache to bucket
run: gsutil rsync -r /root/.cache/ gs://coreum-ci-cache
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ github.workspace }}/coverage/${{ matrix.codecov-name }}
flags: ${{ matrix.codecov-name }}
fail_ci_if_error: true
verbose: true
if: ${{ matrix.codecov }}
- name: Dump docker logs on failure
if: failure()
uses: jwalton/gh-docker-logs@v2