-
Notifications
You must be signed in to change notification settings - Fork 2
32 lines (30 loc) · 876 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
---
name: Test
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test-job:
runs-on: ubuntu-latest
steps:
# checkout and env setup
- uses: actions/checkout@v3
- uses: cachix/install-nix-action@v22
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Build the nix shell
run: nix develop --command just --version
- name: Install Rust toolchain with rustup
run: nix develop --command cargo --version
- uses: Swatinem/rust-cache@v2
# setup databases
- name: Start databases
run: nix develop --command just dbs/start
- name: Seed databases
run: nix develop --command just dbs/seed
# run tests
- name: Run tests
run: nix develop --command just test