-
Notifications
You must be signed in to change notification settings - Fork 70
48 lines (36 loc) · 1.22 KB
/
rust.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
name: Rust
on:
pull_request:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
steps:
- uses: actions/checkout@v3
- name: Install Rust Stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt, clippy
override: true
- uses: Swatinem/rust-cache@v2
- name: Install cargo audit
run: cargo install cargo-audit
- name: Build
run: cargo build --all-targets --verbose
- name: Lint with Clippy
run: cargo clippy --all-targets --all-features --tests --examples -- -D warnings
- name: Run Tests
run: cargo test --all-features --verbose
- name: Run Tests (no ssl)
run: cargo test --no-default-features --verbose
- name: Run Tests (ssl cross)
run: |
cargo test --no-default-features --features ureq,native-tls
cargo test --no-default-features --features ureq,rustls-tls
cargo test --no-default-features --features tokio,native-tls
cargo test --no-default-features --features tokio,rustls-tls
- name: Run Audit
run: cargo audit -D warnings