-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (40 loc) · 1012 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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Check lock file, fmt, clippy
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
pull_request:
push:
branches:
- "main"
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
jobs:
test:
runs-on: ubuntu-22.04
steps:
- name: checkout repo
uses: actions/checkout@v3
- name: set build cache
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
digital-asset-rpc-infrastructure/target/
key: cargo-${{ hashFiles('**/Cargo.lock') }}-0001
# Cargo.lock
- name: Check lock file
run: |
cargo tree
git checkout Cargo.lock
cargo tree
# fmt
- name: Check fmt
run: cargo fmt --all -- --check
# clippy
- name: Check clippy
run: cargo clippy --all-targets --tests -- -Dwarnings