name: Test
on:
pull_request:
branches: ["main"]
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, ubuntu-latest]
toolchain:
- stable
- beta
- nightly
precision: ["", "f32"]
steps:
- uses: actions/checkout@v3
- name: Update
run:
rustup update ${{ matrix.toolchain }} && rustup default ${{
matrix.toolchain }}
- name: Update Git Submodules
run: |
git submodule update --init --remote --recursive
- name: Build with build.rs
run: |
cargo build --verbose --features=${{ matrix.precision }}
- name: Run tests
run: |
cargo test --verbose --features=${{ matrix.precision }}
- name: Build with build.rs (release)
run: |
cargo build --verbose --release --features=${{ matrix.precision }}
- name: Run tests (release)
run: |
cargo test --verbose --release --features=${{ matrix.precision }}