-
Notifications
You must be signed in to change notification settings - Fork 154
92 lines (88 loc) · 2.75 KB
/
Copy pathci.yml
File metadata and controls
92 lines (88 loc) · 2.75 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
name: Continuous integration
on:
push:
branches:
- master
- release/*
pull_request:
env:
RUSTFLAGS: -Dwarnings
jobs:
rustfmt:
runs-on: ubuntu-latest
steps:
- name: Checking out fvm
uses: actions/checkout@v4
- name: Check Format
run: cargo fmt -- --check
- name: Check license headers
run: make license
cargo:
needs: [rustfmt]
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
name: [build, check-clippy, check-m2-native, test-fvm, test, conformance]
include:
- name: build
key: v3
push: true
# we disable default features because rust will otherwise unify them and turn on opencl in CI.
command: build
args: --no-default-features
- name: check-m2-native
key: v3
push: true
command: check
# we disable default features because rust will otherwise unify them and turn on opencl in CI.
args: --features=m2-native --no-default-features
- name: check-clippy
key: v3
command: clippy
# we disable default features because rust will otherwise unify them and turn on opencl in CI.
args: --all --all-targets --no-default-features
- name: test-fvm
key: v3
push: true
command: test
args: --package fvm --no-default-features
- name: test
key: v3
command: test
args: --all --exclude fvm --exclude fvm_conformance_tests
- name: conformance
key: v3
command: test
args: --package fvm_conformance_tests
submodules: true
exclude:
- os: macos-latest
name: check-m2-native
- os: macos-latest
name: check-clippy
- os: macos-latest
name: conformance
- os: macos-latest
name: test
- os: macos-latest
name: test-fvm
env:
CARGO_INCREMENTAL: 0
CARGO_TERM_COLOR: always
name: ${{matrix.os}} - ${{ matrix.name }}
steps:
- name: Checking out fvm
uses: actions/checkout@v4
with:
submodules: ${{ matrix.submodules }}
# we don't check the lockfile in; this is needed for cache restoration/saving
- name: Setting up cache
uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6
with:
save-if: ${{ matrix.push == true }}
# change this to invalidate sccache for this job
prefix-key: ${{ matrix.key }}
- name: Running ${{ matrix.command }}
run: cargo ${{ matrix.command }} --locked ${{ matrix.args }}