Add integration tests with hfjobs #117
Workflow file for this run
This file contains hidden or 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: Rust | |
on: | |
push: | |
branches: [ "main", "hfendpoints-v*.*", "whisper-rust" ] | |
pull_request: | |
branches: [ "main", "hfendpoints-v*.*" ] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
# Basic actions that must pass before we kick off more expensive tests. | |
basics: | |
name: QA Checks | |
runs-on: ubuntu-latest | |
needs: | |
- clippy | |
- fmt | |
steps: | |
- run: exit 0 | |
fmt: | |
name: fmt | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: rustfmt | |
- uses: Swatinem/rust-cache@v2 | |
# Check fmt | |
- name: "rustfmt --check" | |
run: rustfmt --check --edition 2024 | |
clippy: | |
name: clippy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: clippy | |
- uses: Swatinem/rust-cache@v2 | |
# Run clippy | |
- name: "clippy --all" | |
run: cargo clippy --all --tests --all-features --no-deps | |
# docs: | |
# name: docs | |
# runs-on: ${{ matrix.run.os }} | |
# strategy: | |
# matrix: | |
# run: | |
# - os: windows-latest | |
# - os: ubuntu-latest | |
# | |
# steps: | |
# - uses: actions/checkout@v4 | |
# - name: Install Rust ${{ env.rust_nightly }} | |
# uses: dtolnay/rust-toolchain@stable | |
# with: | |
# toolchain: ${{ env.rust_nightly }} | |
# - uses: Swatinem/rust-cache@v2 | |
# - name: "doc --lib --all-features" | |
# run: | | |
# cargo doc --lib --no-deps --all-features --document-private-items | |
# env: | |
# RUSTFLAGS: --cfg docsrs | |
# RUSTDOCFLAGS: --cfg docsrs -Dwarnings | |
hfendpoints-workspace-all-features: | |
needs: basics | |
name: Build & tests hfendpoints | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- windows-latest | |
- ubuntu-latest | |
- macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build | |
run: cargo build --verbose | |
- name: Run tests | |
run: cargo test --verbose |