2023-03-13 10:42:12 +00:00
|
|
|
name: Rust
|
2023-01-12 17:50:12 +00:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
2023-03-13 10:42:12 +00:00
|
|
|
tests:
|
2023-04-05 18:33:37 +00:00
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os:
|
|
|
|
- ubuntu-latest
|
|
|
|
- windows-latest
|
|
|
|
- macos-latest
|
2023-01-12 17:50:12 +00:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
submodules: recursive
|
|
|
|
- name: Get latest version of stable rust
|
2023-03-29 06:59:52 +00:00
|
|
|
run: rustup update stable
|
2023-01-12 17:50:12 +00:00
|
|
|
- name: Build and Test (minimal preset)
|
2023-03-29 06:59:52 +00:00
|
|
|
working-directory: bindings/rust
|
|
|
|
run: cargo test --all --release --features="minimal-spec" --tests
|
|
|
|
- name: Build and Test (mainnet preset)
|
|
|
|
working-directory: bindings/rust
|
|
|
|
run: cargo test --all --release --tests
|
|
|
|
- name: Benchmark
|
|
|
|
working-directory: bindings/rust
|
|
|
|
run: cargo bench
|