-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (52 loc) · 1.35 KB
/
build.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
name: build
on:
push:
branches:
- main
- develop
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
types:
- opened
- reopened
- synchronize
schedule:
- cron: '0 9 * * 3'
workflow_dispatch:
jobs:
run-tests:
name: run-tests-on-${{matrix.channel}}
strategy:
matrix:
name:
- rust-stable
- rust-nightly
include:
- name: rust-stable
channel: stable
- name: rust-nightly
channel: nightly
runs-on: ubuntu-latest
steps:
- name: checkout-${{matrix.channel}}
uses: actions/checkout@v3
- name: setup-toolchain-${{matrix.channel}}
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{matrix.channel}}
override: true
components: rustfmt
- name: cargo-build-${{matrix.channel}}
run: cargo build
- name: cargo-check-${{matrix.channel}}
run: cargo check
- name: cargo-check-formatting-${{matrix.channel}}
run: cargo fmt --check
- name: cargo-test-${{matrix.channel}}
run: cargo test --all-features
- name: cargo-test-doc-${{matrix.channel}}
run: cargo test --all-features --doc
- name: cargo-test-examples-${{matrix.channel}}
run: cargo test --all-features --examples