2022-07-22 16:31:29 +00:00
|
|
|
name: Tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- develop
|
|
|
|
pull_request:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
clippy:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
submodules: "recursive"
|
|
|
|
|
2022-07-23 11:05:31 +00:00
|
|
|
- name: Build Dependencies
|
|
|
|
uses: ./.github/actions/build-dependencies
|
2022-07-22 16:31:29 +00:00
|
|
|
with:
|
|
|
|
# Clippy requires nightly for some reason
|
2022-07-29 14:36:09 +00:00
|
|
|
rust-toolchain: nightly
|
|
|
|
rust-components: clippy
|
2022-07-22 16:31:29 +00:00
|
|
|
|
|
|
|
- name: Run Clippy
|
|
|
|
run: cargo clippy --all-features -- -D warnings -A clippy::type_complexity -A dead_code
|
|
|
|
|
|
|
|
test:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
submodules: "recursive"
|
|
|
|
|
2022-07-29 14:36:09 +00:00
|
|
|
- name: Test Dependencies
|
|
|
|
uses: ./.github/actions/test-dependencies
|
2022-07-22 16:31:29 +00:00
|
|
|
|
2022-07-29 14:36:09 +00:00
|
|
|
- name: Run Tests
|
2022-07-22 16:31:29 +00:00
|
|
|
run: cargo test --all-features
|
|
|
|
|
|
|
|
fmt:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
|
2022-07-29 14:36:09 +00:00
|
|
|
# Doesn't grab the cache as it's not needed
|
2022-07-22 16:31:29 +00:00
|
|
|
- name: Install rustfmt
|
|
|
|
uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
toolchain: nightly
|
|
|
|
profile: minimal
|
|
|
|
components: rustfmt
|
|
|
|
|
|
|
|
- name: Run rustfmt
|
|
|
|
run: cargo +nightly fmt -- --check
|