Dev13 #35
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: Triple Arena CI | |
on: [pull_request] | |
env: | |
RUSTFLAGS: -D warnings | |
RUST_BACKTRACE: 1 | |
jobs: | |
test_suite: | |
name: Test suite | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Rust components | |
run: | | |
rustup set profile minimal | |
rustup default stable | |
rustup target add riscv32i-unknown-none-elf | |
- name: Run test suite | |
# The `riscv32i` build is needed to actually detect if the crate is no_std. | |
# The `-p triple_arena` builds are so that the testcrate isn't always activating flags | |
# Note that the test crate has a serde_support flag | |
run: | | |
cargo b --target=riscv32i-unknown-none-elf -p no_std_test | |
cargo b --no-default-features -p triple_arena | |
cargo b --no-default-features --features=serde -p triple_arena | |
cargo b --no-default-features --features=expose_internal_utils -p triple_arena | |
cargo b --no-default-features | |
cargo b --all-features | |
cargo t --no-default-features | |
cargo t --all-features | |
cargo t --release --all-features | |
cargo r --bin render0 | |
cargo r --bin render1 | |
cargo r --example equation | |
miri: | |
name: Miri | |
runs-on: ubuntu-latest | |
# note: we have turned on this Miri flag | |
env: | |
RUSTFLAGS: -D warnings | |
MIRIFLAGS: -Zmiri-tree-borrows -Zmiri-strict-provenance | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install most recent Miri | |
run: | | |
rustup set profile minimal | |
rustup default "nightly-$(curl -s https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/miri)" | |
rustup component add miri | |
- name: Run test suite with Miri | |
run: | | |
cargo miri test | |
msrv_test_suite: | |
runs-on: ubuntu-latest | |
env: | |
RUSTFLAGS: -D warnings | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Rust components | |
run: | | |
rustup set profile minimal | |
rustup install nightly-2023-04-14 | |
- name: Run test suite | |
run: | | |
cargo build --no-default-features | |
rustfmt: | |
name: Rustfmt | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
# Acquire the most recent nightly with a rustfmt component | |
- name: Install most recent Rustfmt | |
run: | | |
rustup set profile minimal | |
rustup default "nightly-$(curl -s https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/rustfmt)" | |
rustup component add rustfmt | |
- name: Run `cargo fmt` | |
run: | | |
cargo fmt -- --check | |
clippy: | |
name: Clippy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
# Acquire the most recent nightly with a clippy component | |
- name: Install most recent Clippy | |
run: | | |
rustup set profile minimal | |
rustup default "nightly-$(curl -s https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/clippy)" | |
rustup component add clippy | |
- name: Run `cargo clippy` | |
run: | | |
cargo clippy --all --all-targets --all-features -- -D clippy::all | |
cargo clippy --all --all-targets --no-default-features -- -D clippy::all |