ci: basic GA for unit tests on various platforms

This commit is contained in:
Antoine Poinsot 2022-07-22 11:25:56 +02:00
parent b0196ab529
commit 8626e05a55
No known key found for this signature in database
GPG Key ID: E13FC145CD3F4304

40
.github/workflows/main.yml vendored Normal file
View File

@ -0,0 +1,40 @@
name: CI
on: [pull_request]
jobs:
linter:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt
override: true
- name: rustfmt
run: cargo fmt -- --check
unit_tests:
needs: linter
strategy:
matrix:
toolchain:
- 1.48
- nightly
os:
- ubuntu-latest
- macOS-latest
- windows-latest
runs-on: ${{ matrix.os }}
steps:
- name: Checkout source code
uses: actions/checkout@v2
- name: Install Rust ${{ matrix.toolchain }} toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.toolchain }}
override: true
profile: minimal
- name: Test on Rust ${{ matrix.toolchain }}
run: cargo test --verbose