Initial commit of the olympus protocol #5
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: Test | |
on: | |
pull_request: | |
push: | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust Toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
override: true | |
components: rustfmt, clippy | |
- name: Install cargo nextest | |
uses: baptiste0928/cargo-install@v1 | |
with: | |
crate: cargo-nextest | |
locked: true | |
- name: Run sccache-cache | |
uses: mozilla-actions/[email protected] | |
- name: Run tests | |
run: cargo nextest run | |
env: | |
# Enable sccache | |
SCCACHE_GHA_ENABLED: "true" | |
RUSTC_WRAPPER: "sccache" | |
check-formatting: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust Toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
override: true | |
components: rustfmt | |
- name: Run sccache-cache | |
uses: mozilla-actions/[email protected] | |
- name: Check formatting | |
run: cargo fmt --check | |
env: | |
# Enable sccache | |
SCCACHE_GHA_ENABLED: "true" | |
RUSTC_WRAPPER: "sccache" | |
cargo-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust Toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
override: true | |
profile: minimal | |
- name: Run sccache-cache | |
uses: mozilla-actions/[email protected] | |
- name: Cargo Check | |
run: cargo check --all | |
env: | |
# Enable sccache | |
SCCACHE_GHA_ENABLED: "true" | |
RUSTC_WRAPPER: "sccache" | |
clippy-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust Toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
override: true | |
components: rustfmt, clippy | |
- name: Run sccache-cache | |
uses: mozilla-actions/[email protected] | |
- name: Clippy Check | |
run: cargo clippy --all | |
env: | |
# Enable sccache | |
SCCACHE_GHA_ENABLED: "true" | |
RUSTC_WRAPPER: "sccache" |