forked from anza-xyz/agave
-
Notifications
You must be signed in to change notification settings - Fork 0
182 lines (163 loc) · 5.22 KB
/
downstream-project-spl.yml
File metadata and controls
182 lines (163 loc) · 5.22 KB
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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
name: Downstream Project - SPL
on:
push:
branches:
- master
- v[0-9]+.[0-9]+
pull_request:
branches:
- master
- v[0-9]+.[0-9]+
paths:
- "**.rs"
- "rust-toolchain.toml"
- "Cargo.toml"
- "Cargo.lock"
- "cargo-build-sbf"
- "cargo-test-sbf"
- "ci/downstream-projects/run-spl.sh"
- ".github/workflows/downstream-project-spl.yml"
- ".github/scripts/downstream-project-spl-common.sh"
- ".github/scripts/downstream-project-spl-install-deps.sh"
workflow_call:
inputs:
branch:
required: false
type: string
default: "master"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
SHELL: /bin/bash
SCCACHE_GHA_ENABLED: "true"
RUSTC_WRAPPER: "sccache"
jobs:
check:
#if: github.repository == 'anza-xyz/agave'
if: false
runs-on: ubuntu-latest
timeout-minutes: 60
strategy:
matrix:
programs:
- associated-token-account
- feature-proposal
- instruction-padding
- memo
- record
- single-pool
- slashing
- stake-pool
- token-2022
# re-enable with https://github.com/buffalojoec/mollusk/pull/74
# - token
steps:
- uses: actions/checkout@v5
- shell: bash
run: |
.github/scripts/purge-ubuntu-runner.sh
- uses: mozilla-actions/sccache-action@v0.0.9
with:
version: "v0.10.0"
- shell: bash
run: |
source .github/scripts/downstream-project-spl-install-deps.sh
source .github/scripts/downstream-project-spl-common.sh "${{ matrix.programs }}"
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
cargo check
test_cli:
#if: github.repository == 'anza-xyz/agave'
if: false
runs-on: ubuntu-latest
timeout-minutes: 60
strategy:
matrix:
programs:
- single-pool
- token-2022
steps:
- uses: actions/checkout@v5
- shell: bash
run: |
.github/scripts/purge-ubuntu-runner.sh
- uses: mozilla-actions/sccache-action@v0.0.9
with:
version: "v0.10.0"
- shell: bash
run: |
source .github/scripts/downstream-project-spl-install-deps.sh
source .github/scripts/downstream-project-spl-common.sh "${{ matrix.programs }}"
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
$CARGO_BUILD_SBF --manifest-path program/Cargo.toml
cargo test --manifest-path clients/cli/Cargo.toml
cargo-test-sbf:
#if: github.repository == 'anza-xyz/agave'
if: false
runs-on: ubuntu-latest
timeout-minutes: 60
strategy:
matrix:
programs:
- associated-token-account
- feature-proposal
- instruction-padding
- memo
- record
- single-pool
- slashing
- stake-pool
- token-2022
# re-enable with https://github.com/buffalojoec/mollusk/pull/74
# - token
steps:
- uses: actions/checkout@v5
- shell: bash
run: |
.github/scripts/purge-ubuntu-runner.sh
- uses: mozilla-actions/sccache-action@v0.0.9
with:
version: "v0.10.0"
- name: Install dependencies
shell: bash
run: |
source .github/scripts/downstream-project-spl-install-deps.sh
source .github/scripts/downstream-project-spl-common.sh "${{ matrix.programs }}"
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
- name: Test SBPFv0
shell: bash
run: |
source ci/downstream-projects/common.sh
cd "${{ matrix.programs }}"
$CARGO_BUILD_SBF --arch v0 --manifest-path program/Cargo.toml
RUSTFLAGS="-Awarnings" SBF_OUT_DIR="../target/deploy" cargo test --features test-sbf --manifest-path program/Cargo.toml
- name: Test SBPFv1
shell: bash
run: |
source ci/downstream-projects/common.sh
cd "${{ matrix.programs }}"
rm -rf target/deploy target/sbpf*
$CARGO_BUILD_SBF --arch v1 --manifest-path program/Cargo.toml
RUSTFLAGS="-Awarnings" SBF_OUT_DIR="../target/deploy" cargo test --features test-sbf --manifest-path program/Cargo.toml
- name: Test SBPFv2
shell: bash
run: |
source ci/downstream-projects/common.sh
cd "${{ matrix.programs }}"
rm -rf target/deploy target/sbpf*
$CARGO_BUILD_SBF --arch v2 --manifest-path program/Cargo.toml
RUSTFLAGS="-Awarnings" SBF_OUT_DIR="../target/deploy" cargo test --features test-sbf --manifest-path program/Cargo.toml
- name: Test SBPFv3
shell: bash
run: |
source ci/downstream-projects/common.sh
cd "${{ matrix.programs }}"
rm -rf target/deploy target/sbpf*
$CARGO_BUILD_SBF --arch v3 --manifest-path program/Cargo.toml
RUSTFLAGS="-Awarnings" SBF_OUT_DIR="../target/deploy" cargo test --features test-sbf --manifest-path program/Cargo.toml