@@ -159,3 +159,61 @@ jobs:
159
159
- name : Mithril Stake Distribution / download & restore latest
160
160
shell : bash
161
161
run : ${{ steps.command.outputs.mithril_client }} ${{ steps.prepare.outputs.debug_level }} mithril-stake-distribution download $MITHRIL_STAKE_DISTRIBUTION_HASH --download-dir /app
162
+
163
+ test-mithril-client-wasm :
164
+ strategy :
165
+ fail-fast : false
166
+ matrix :
167
+ os : [ ubuntu-22.04, macos-12, windows-latest ]
168
+ runs-on : ${{ matrix.os }}
169
+ steps :
170
+ - name : Checkout sources
171
+ uses : actions/checkout@v3
172
+
173
+ - name : Prepare environment variables
174
+ id : prepare
175
+ shell : bash
176
+ run : |
177
+ if [[ -n "${{ inputs.commit_sha }}" ]]; then
178
+ echo "sha=${{ inputs.commit_sha }}" >> $GITHUB_OUTPUT
179
+ else
180
+ echo "branch=main" >> $GITHUB_OUTPUT
181
+ fi
182
+
183
+ if [[ "${{ inputs.enable_debug }}" == "true" ]]; then
184
+ echo "debug_level=-vvv" >> $GITHUB_OUTPUT
185
+ fi
186
+
187
+ echo "NETWORK=${{ inputs.network }}" >> $GITHUB_ENV
188
+ echo "AGGREGATOR_ENDPOINT=${{ inputs.aggregator_endpoint }}" >> $GITHUB_ENV
189
+ echo "GENESIS_VERIFICATION_KEY=$(curl -s ${{ inputs.genesis_verification_key }})" >> $GITHUB_ENV
190
+
191
+ - name : Download built artifacts
192
+ uses : dawidd6/action-download-artifact@v2
193
+ with :
194
+ name : mithril-distribution-wasm
195
+ path : ./bin
196
+ commit : ${{ steps.prepare.outputs.sha }}
197
+ branch : ${{ steps.prepare.outputs.branch }}
198
+ workflow : ci.yml
199
+ workflow_conclusion : success
200
+
201
+ - name : Unpack 'mithril-client-wasm' package
202
+ working-directory : mithril-client-wasm
203
+ run :
204
+ tar -xvzf pkg/*.tgz -C pkg/ && mv pkg/package/* pkg/
205
+
206
+ - name : Setup Node.js
207
+ uses : actions/setup-node@v3
208
+ with :
209
+ node-version : 18
210
+ cache : ' npm'
211
+ cache-dependency-path : mithril-client-wasm/www-ci/package-lock.lock
212
+
213
+ - name : Install dependencies
214
+ working-directory : mithril-client-wasm
215
+ run : make www-test-install
216
+
217
+ - name : Build Explorer
218
+ working-directory : mithril-client-wasm
219
+ run : make www-test-serve
0 commit comments