2020-06-22 11:10:33 -04:00
|
|
|
name: Rust
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ master ]
|
|
|
|
pull_request:
|
|
|
|
branches: [ master ]
|
|
|
|
|
|
|
|
env:
|
|
|
|
CARGO_TERM_COLOR: always
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Build
|
2022-01-13 12:15:14 -05:00
|
|
|
run: cargo build --all-features
|
2022-01-13 11:52:06 -05:00
|
|
|
|
2022-01-13 12:15:14 -05:00
|
|
|
test:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Test
|
|
|
|
run: cargo test --all-features
|
2022-01-13 11:52:06 -05:00
|
|
|
|
2022-01-13 12:15:14 -05:00
|
|
|
coverage:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2022-01-13 12:19:34 -05:00
|
|
|
- name: Run cargo-tarpaulin
|
|
|
|
uses: actions-rs/tarpaulin@v0.1
|
2022-01-13 11:52:06 -05:00
|
|
|
with:
|
2022-01-13 12:04:12 -05:00
|
|
|
version: '0.19.0'
|
2022-01-13 12:15:14 -05:00
|
|
|
args: --all-features --out=Xml
|
2022-01-13 11:52:06 -05:00
|
|
|
|
|
|
|
- name: Upload to codecov.io
|
|
|
|
uses: codecov/codecov-action@v2
|
|
|
|
with:
|
|
|
|
token: ${{secrets.CODECOV_TOKEN}}
|
|
|
|
|
|
|
|
- name: Archive code coverage results
|
|
|
|
uses: actions/upload-artifact@v1
|
2022-01-13 10:52:27 -05:00
|
|
|
with:
|
2022-01-13 11:52:06 -05:00
|
|
|
name: code-coverage-report
|
2022-01-13 11:56:20 -05:00
|
|
|
path: cobertura.xml
|