-
Notifications
You must be signed in to change notification settings - Fork 12
102 lines (95 loc) · 2.69 KB
/
main.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
on: [push, pull_request]
name: Continuous integration
jobs:
fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Running cargo fmt
run: cargo fmt --all -- --check
simpcli_test:
name: SimpCLI Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@stable
- name: Running cargo test
run: |
cd simpcli
cargo test
bench_test:
name: Jets-Bench Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@stable
- name: Running cargo test
run: |
cargo install cargo-criterion
cd jets-bench
cargo test
cargo criterion --no-run
test:
name: Tests
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- stable
- beta
- nightly
- 1.58.0
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
- name: Set dependencies
run: cp Cargo-recent.lock Cargo.lock
- name: Running cargo test
env:
FEATURES: bitcoin elements test-utils
run: |
for f in $FEATURES; do echo "Features: $f" && cargo test --locked --no-default-features --features="$f"; done
cd simplicity-sys
cargo test --locked --no-default-features
cargo test --locked --features="test-utils"
echo "No default features" && cargo test --locked --no-default-features
echo "All features" && cargo test --locked --all-features
ignored:
name: Ignored Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@stable
- name: Running cargo test
run: cargo test -- --ignored
clippy:
name: Clippy
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout Crate
uses: actions/checkout@v4
- name: Checkout Toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- name: Running cargo clippy
run: cargo clippy --all-targets -- --deny warnings