-
Notifications
You must be signed in to change notification settings - Fork 27
46 lines (38 loc) · 977 Bytes
/
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
name: ci
on:
pull_request:
branches:
- main
push:
branches:
- main
env:
CARGO_TERM_COLOR: always
RUST_BACKTRACE: 1
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
# Cache cargo registry, index, and build directories
- name: Cache cargo
uses: actions/cache@v2
with:
path: |
~/.cargo
key: cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Build
run: cargo build --verbose
- name: Generate test results
run: |
mkdir test-results;
cargo install cargo2junit;
cargo +nightly test -- -Z unstable-options --format json | cargo2junit > test-results/tests.xml;
- name: Create Github test summary
uses: test-summary/action@dist
with:
paths: test-results/**/*.xml
if: always()