fayalite/.forgejo/workflows/test.yml

22 lines
777 B
YAML
Raw Normal View History

2024-06-11 22:13:07 -07:00
on: [push, pull_request]
jobs:
test:
runs-on: debian-12
steps:
- uses: https://code.forgejo.org/actions/checkout@v3
with:
fetch-depth: 0
- run: |
2024-06-11 22:15:23 -07:00
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain none
source "$HOME/.cargo/env"
echo "$PATH" >> "$GITHUB_PATH"
2024-06-11 22:13:07 -07:00
- run: |
2024-06-11 22:15:23 -07:00
# override server since 1.79.0 is not quite stable yet,
# it should be in a few days -- on 2024-06-13
RUSTUP_DIST_SERVER=https://dev-static.rust-lang.org rustup install 1.79.0
rustup default 1.79.0
2024-06-11 22:20:22 -07:00
- uses: https://github.com/Swatinem/rust-cache@v2
2024-06-11 22:13:07 -07:00
with:
save-if: ${{ github.ref == 'refs/heads/master' }}
- run: cargo test