mirror of
https://github.com/serai-dex/serai.git
synced 2024-10-31 17:37:38 +00:00
18a1d15f78
* Attempt composite actions in CI * Remove needs monero-daemon for the action * Correct actions folder layout * Remove empty inputs/outputs, add shell * Try moving env declaration spot * Remove usage of env * Cached Rust composite action * Replace [] with "" Remove empty outputs
68 lines
1.5 KiB
YAML
68 lines
1.5 KiB
YAML
name: Tests
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- develop
|
|
pull_request:
|
|
|
|
jobs:
|
|
clippy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
submodules: "recursive"
|
|
|
|
- name: Build Dependencies
|
|
uses: ./.github/actions/build-dependencies
|
|
|
|
- name: Install Rust
|
|
uses: ./.github/actions/cached-rust
|
|
with:
|
|
# Clippy requires nightly for some reason
|
|
toolchain: nightly
|
|
components: clippy
|
|
|
|
- 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"
|
|
|
|
- name: Build Dependencies
|
|
uses: ./.github/actions/build-dependencies
|
|
|
|
- name: Install Foundry
|
|
uses: foundry-rs/foundry-toolchain@v1
|
|
with:
|
|
version: nightly
|
|
|
|
- name: Monero Regtest Daemon
|
|
uses: ./.github/actions/monero
|
|
|
|
- name: Install Rust
|
|
uses: ./.github/actions/cached-rust
|
|
|
|
- name: Run tests
|
|
run: cargo test --all-features
|
|
|
|
fmt:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
|
|
# Doesn't grab the cache because it doesn't need it
|
|
- name: Install rustfmt
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: nightly
|
|
profile: minimal
|
|
components: rustfmt
|
|
|
|
- name: Run rustfmt
|
|
run: cargo +nightly fmt -- --check
|