forked from 0xPolygon/polygon-edge
-
Notifications
You must be signed in to change notification settings - Fork 7
165 lines (164 loc) · 5.11 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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
---
name: CI
on: # yamllint disable-line rule:truthy
push:
branches:
- main
- develop
pull_request:
workflow_dispatch:
inputs:
build_blade:
description: Build Blade
type: boolean
default: true
lint:
description: Lint
type: boolean
default: true
unit_test:
description: Unit Tests
type: boolean
default: true
e2e_polybft_test:
description: E2E PolyBFT Tests
type: boolean
default: true
e2e_legacy_test:
description: E2E Legacy Tests
type: boolean
default: true
property_polybft_test:
description: Property PolyBFT Tests
type: boolean
default: true
fuzz_test:
description: Fuzz Tests
type: boolean
default: true
benchmark_test:
description: Benchmark Tests
type: boolean
default: true
workflow_call:
inputs:
build_blade:
description: Build Blade
type: boolean
lint:
description: Lint
type: boolean
required: true
unit_test:
description: Unit Tests
type: boolean
required: true
e2e_polybft_test:
description: E2E PolyBFT Tests
type: boolean
required: true
e2e_legacy_test:
description: E2E Legacy Tests
type: boolean
required: true
property_polybft_test:
description: Property PolyBFT Tests
type: boolean
required: true
fuzz_test:
description: Fuzz Tests
type: boolean
required: true
benchmark_test:
description: Benchmark Tests
type: boolean
required: true
outputs:
build_blade:
description: Build Blade output
value: ${{ jobs.build_blade.outputs.workflow_output }}
lint:
description: Lint output
value: ${{ jobs.lint.outputs.workflow_output }}
unit_test:
description: Unit Tests output
value: ${{ jobs.unit_test.outputs.workflow_output }}
e2e_polybft_test:
description: E2E PolyBFT Tests output
value: ${{ jobs.e2e_polybft_test.outputs.workflow_output }}
e2e_legacy_test:
description: E2E Legacy Tests output
value: ${{ jobs.e2e_legacy_test.outputs.workflow_output }}
property_polybft_test:
description: Property PolyBFT Tests output
value: ${{ jobs.property_polybft_test.outputs.workflow_output }}
fuzz_test:
description: Fuzz Tests output
value: ${{ jobs.fuzz_test.outputs.workflow_output }}
benchmark_test:
description: Benchmark Tests output
value: ${{ jobs.benchmark_test.outputs.workflow_output }}
jobs:
build_blade:
name: Build Blade
uses: ./.github/workflows/build.yml
if: |
inputs.build_blade ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
lint:
name: Lint
uses: ./.github/workflows/lint.yml
needs: build_blade
if: |
inputs.lint ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
unit_test:
name: Unit Tests
uses: ./.github/workflows/unit-test.yml
needs: build_blade
if: |
inputs.unit_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
e2e_polybft_test:
name: E2E PolyBFT Tests
uses: ./.github/workflows/e2e-polybft-test.yml
needs: build_blade
if: |
inputs.e2e_polybft_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
e2e_legacy_test:
name: E2E Legacy Tests
uses: ./.github/workflows/e2e-legacy-test.yml
needs: build_blade
if: |
inputs.e2e_legacy_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
property_polybft_test:
name: Property PolyBFT Tests
uses: ./.github/workflows/property-polybft-test.yml
needs: build_blade
if: |
inputs.property_polybft_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
fuzz_test:
name: Fuzz Tests
uses: ./.github/workflows/fuzz-test.yml
needs: build_blade
if: |
inputs.fuzz_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))
benchmark_test:
name: Benchmark Tests
uses: ./.github/workflows/benchmark-test.yml
needs: build_blade
if: |
inputs.benchmark_test ||
github.event_name == 'pull_request' ||
(github.event_name == 'push' && (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'))