-
Notifications
You must be signed in to change notification settings - Fork 4
39 lines (37 loc) · 1.04 KB
/
codecov.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
name: Codecov
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
Codecov:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust (rustup)
working-directory: ./sim
run: rustup update stable && rustup default stable
- name: Generate Cargo.lock
working-directory: ./sim
run: cargo generate-lockfile
- uses: actions/cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
./sim/target
key: ${{ runner.os }}-cargo-${{ hashFiles('./sim/Cargo.lock') }}
- name: Build (wasm-pack)
working-directory: ./sim
run: |
curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
wasm-pack build
- name: Push Coverage Data (codecov)
working-directory: ./sim
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
run: |
cargo install cargo-tarpaulin &&
cargo tarpaulin --all-features --out xml &&
bash <(curl -s https://codecov.io/bash)