-
Notifications
You must be signed in to change notification settings - Fork 19
88 lines (83 loc) · 2.39 KB
/
Copy pathrust_ci.yml
File metadata and controls
88 lines (83 loc) · 2.39 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
name: Rust CI
on:
push:
branches: [ main ]
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
cargo-tests:
runs-on: ubuntu-latest
name: test
steps:
- name: Checkout sources
uses: actions/checkout@v6
- uses: ./.github/actions/setup
with:
components: rustfmt
- uses: taiki-e/install-action@nextest
- name: cargo test
run: cargo nextest run --workspace --all-features
cargo-lint:
runs-on: ubuntu-latest
name: lint
steps:
- name: Checkout sources
uses: actions/checkout@v6
- uses: ./.github/actions/setup
with:
channel: stable
components: rustfmt,clippy
- name: lint
run: make lint
- name: fmt
run: make fmt
cargo-build:
runs-on: ubuntu-latest
name: build
steps:
- name: Checkout sources
uses: actions/checkout@v6
- uses: ./.github/actions/setup
with:
channel: stable
- name: build
run: cargo build --all-targets --all-features
cargo-audit:
runs-on: ubuntu-latest
name: audit
steps:
- name: Checkout sources
uses: actions/checkout@v6
- uses: ./.github/actions/setup
with:
channel: stable
- uses: taiki-e/install-action@cargo-audit
- name: audit
run: cargo audit
blind-threshold-bls-wasm-tests:
runs-on: ubuntu-latest
name: blind-threshold-bls-wasm-tests
steps:
- name: Checkout sources
uses: actions/checkout@v6
- uses: ./.github/actions/setup
with:
channel: stable
- run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
- name: build
run: cd crates/threshold-bls-ffi && wasm-pack build --target nodejs -- --features=wasm
- name: Upload wasm pkg artifact
uses: actions/upload-artifact@v7
with:
name: wasm-pkg
path: crates/threshold-bls-ffi/pkg
- uses: actions/setup-node@v6
- name: Run blind-threshold-bls-wasm tests
run: |
git clone https://github.com/celo-org/blind-threshold-bls-wasm.git $RUNNER_TEMP/blind-threshold-bls-wasm
rm $RUNNER_TEMP/blind-threshold-bls-wasm/src/blind*
cp -r crates/threshold-bls-ffi/pkg/blind* $RUNNER_TEMP/blind-threshold-bls-wasm/src/
cd $RUNNER_TEMP/blind-threshold-bls-wasm
npm ci
npm test