forked from gnolang/gno
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (49 loc) · 1.55 KB
/
genesis-verify.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
name: genesis-verify
on:
pull_request:
branches:
- master
paths:
- "misc/deployments/**/genesis.json"
- ".github/workflows/genesis-verify.yml"
jobs:
verify:
strategy:
fail-fast: false
matrix:
testnet: ["test5.gno.land"]
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v45
with:
files: "misc/deployments/${{ matrix.testnet }}/genesis.json"
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: contribs/gnogenesis/go.mod
- name: Build gnogenesis
run: make -C contribs/gnogenesis
- name: Verify each genesis file
run: |
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do
echo "Verifying $file"
gnogenesis verify -genesis-path $file
done
- name: Build gnoland
run: make -C gno.land install.gnoland
- name: Running latest gnoland with each genesis file
run: |
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do
echo "Running gnoland with $file"
timeout 60s gnoland start -lazy --genesis $file || exit_code=$?
if [ $exit_code -eq 124 ]; then
echo "Gnoland genesis state generated successfully"
else
echo "Gnoland failed to start with $file"
exit 1
fi
done