forked from sanlee42/schemars
-
Notifications
You must be signed in to change notification settings - Fork 52
50 lines (48 loc) · 1.63 KB
/
ci.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
name: CI
on: [push, pull_request, workflow_dispatch]
jobs:
ci:
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- 1.37.0
- stable
- beta
- nightly
include:
- rust: 1.37.0
# exclude ui_test as the output is slightly different in rustc 1.37
test_features: "--features impl_json_schema,chrono,indexmap,either,uuid,smallvec,arrayvec,enumset"
allow_failure: false
- rust: stable
test_features: "--all-features"
allow_failure: false
- rust: beta
test_features: "--all-features"
allow_failure: false
- rust: nightly
test_features: "--all-features"
allow_failure: true
fail-fast: false
steps:
- uses: actions/checkout@v1
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- name: Check with no feature flags
run: cargo check --verbose --no-default-features
continue-on-error: ${{ matrix.allow_failure }}
working-directory: ./schemars
- if: matrix.rust == '1.37.0'
run: cargo update -p indexmap --precise 1.6.2
- name: Run tests
run: cargo test --verbose ${{ matrix.test_features }} --no-fail-fast
continue-on-error: ${{ matrix.allow_failure }}
working-directory: ./schemars
- name: Run derive tests
run: cargo test --verbose --all-features --no-fail-fast
continue-on-error: ${{ matrix.allow_failure }}
working-directory: ./schemars_derive