-
Notifications
You must be signed in to change notification settings - Fork 22
78 lines (69 loc) · 2.12 KB
/
test_rust.yml
File metadata and controls
78 lines (69 loc) · 2.12 KB
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Test binary-install-example
on: [pull_request]
jobs:
test:
name: Test
runs-on: ${{ matrix.os }}
strategy:
matrix:
build:
[
linux-stable,
linux-nightly,
macos-stable,
macos-nightly,
windows-stable,
windows-nightly,
]
include:
- build: linux-stable
os: ubuntu-latest
rust: stable
- build: macos-stable
os: macos-latest
rust: stable
- build: windows-stable
os: windows-latest
rust: stable
- build: linux-nightly
os: ubuntu-latest
rust: nightly
- build: macos-nightly
os: macos-latest
rust: nightly
- build: windows-nightly
os: windows-latest
rust: nightly
steps:
- uses: actions/checkout@v1
- name: Cache Cargo registry
uses: actions/cache@v1
with:
path: ~/.cargo/registry
key: ${{ matrix.build }}-${{ matrix.rust }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ matrix.build }}-${{ matrix.rust }}-cargo-registry-
- name: Cache Cargo index
uses: actions/cache@v1
with:
path: ~/.cargo/git
key: ${{ matrix.build }}-${{ matrix.rust }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ matrix.build }}-${{ matrix.rust }}-cargo-index-
- name: Cache Cargo build
uses: actions/cache@v1
with:
path: target/debug
key: ${{ matrix.build }}-${{ matrix.rust }}-debug-target-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ matrix.build }}-${{ matrix.rust }}-debug-target-
- name: Install Rust
run: |
rustup update ${{ matrix.rust }} --no-self-update
rustup default ${{ matrix.rust }}
- name: Run Tests
working-directory: ./example-binary
run: cargo test
env:
RUST_LOG: warn,wrangler=info
RUST_BACKTRACE: 1