-
-
Notifications
You must be signed in to change notification settings - Fork 1
55 lines (52 loc) · 1.35 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
52
53
54
55
name: Test & Lint
on:
push:
branches: ["*"]
paths:
- ".github/workflows/test.yml"
- "**/*.rs"
- "**/*.md" # Test examples in markdowns included as API doc
- "**/Cargo.toml"
pull_request:
branches: ["*"]
paths:
- ".github/workflows/test.yml"
- "**/*.rs"
- "**/*.md" # Test examples in markdowns included as API doc
- "**/Cargo.toml"
env:
CARGO_TERM_COLOR: always
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
rust: [stable, beta, nightly]
runs-on: ${{ matrix.os }}
timeout-minutes: 2
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Build
run: cargo build --verbose
- name: Test
run: cargo test --verbose -- --show-output --include-ignored
lint:
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
components: rustfmt, clippy
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features
- name: Lint
run: cargo clippy --verbose -- -D warnings