update #17
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check Rust | ||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
env: | ||
CARGO_TERM_COLOR: always | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Install Rustup | ||
run: | | ||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y | ||
source ~/.cargo/env | ||
rustup default nightly | ||
rustup update nightly | ||
rustup update stable | ||
rustup target add wasm32-unknown-unknown --toolchain nightly | ||
- name: Check | ||
run: cargo check --verbose | ||
- name: Build | ||
run: cargo build --verbose | ||
- name: Check code format | ||
run: cargo fmt -- --check | ||
- name: Lint rust sources | ||
run: cargo clippy --all-targets --all-features --tests --benches -- -D warnings | ||
- name: Check Build for Benchmarking | ||
run: cargo check --features=runtime-benchmarks --release | ||
# - name: Run tests | ||
# run: cargo test --all-features -- --test-threads=1 --nocapture | ||
# - name: Check no_std support | ||
# run: argo check --no-default-features --target=wasm32-unknown-unknown | ||