-
Notifications
You must be signed in to change notification settings - Fork 4
51 lines (43 loc) · 1.12 KB
/
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
50
51
name: test
on: [push, pull_request]
jobs:
build:
name: ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-11, ubuntu-latest, windows-latest]
env:
CARGO_INCREMENTAL: 0
RUST_BACKTRACE: full
CARGO_TERM_COLOR: always
steps:
- name: Clone repository
uses: actions/checkout@v3
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: target/*/build
- name: Configure cargo data directory
run: |
echo "CARGO_HOME=$(pwd)/.cargo_home" >> $GITHUB_ENV
- name: Cache
uses: actions/cache@v2
with:
path: |-
.cargo_home
target/*/.*
target/*/build
target/*/deps
key: ${{ matrix.os }}-${{ hashFiles('Cargo.lock') }}
restore-keys: |
${{ matrix.os }}-
- name: Run cargo test
run: |
tar --version
tar --help
make test
- name: Run command
run: cargo run -- --help