Skip to content

Commit c0614af

Browse files
committed
Improve github action configuration
1 parent 3762a01 commit c0614af

File tree

1 file changed

+46
-7
lines changed

1 file changed

+46
-7
lines changed

.github/workflows/push-check.yml

Lines changed: 46 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,54 @@ name: Push Check
33
on: [push]
44

55
jobs:
6-
build:
7-
6+
build_and_test:
7+
runs-on: ${{ matrix.os }}
8+
strategy:
9+
matrix:
10+
os: [ubuntu-latest, windows-latest, macos-latest]
11+
steps:
12+
- uses: actions/checkout@v1
13+
with:
14+
submodules: recursive
15+
- uses: actions-rs/toolchain@v1
16+
with:
17+
toolchain: stable
18+
override: true
19+
- uses: actions-rs/cargo@v1
20+
with:
21+
command: test
22+
args: --verbose
23+
- uses: actions-rs/cargo@v1
24+
with:
25+
command: test
26+
args: --verbose --no-default-features --lib
27+
test_all_features:
828
runs-on: ubuntu-latest
9-
1029
steps:
1130
- uses: actions/checkout@v1
1231
with:
1332
submodules: recursive
14-
- name: Build
15-
run: cargo build --verbose --all-features
16-
- name: Run tests
17-
run: cargo test --verbose --all-features
33+
- uses: actions-rs/toolchain@v1
34+
with:
35+
toolchain: stable
36+
override: true
37+
- uses: actions-rs/cargo@v1
38+
with:
39+
command: test
40+
args: --verbose --all-features
41+
run_all_examples:
42+
runs-on: ubuntu-latest
43+
steps:
44+
- uses: actions/checkout@v1
45+
with:
46+
submodules: recursive
47+
- uses: actions-rs/cargo@v1
48+
with:
49+
command: build
50+
args: --verbose --release --examples
51+
- name: Run all the examples
52+
run: for example in examples/*.rs; do ./target/release/examples/$(basename ${example} .rs); done && tar -czvf example-outputs.tar.gz plotters-doc-data
53+
- uses: actions/upload-artifact@v1
54+
with:
55+
name: example-outputs
56+
path: example-outputs.tar.gz

0 commit comments

Comments
 (0)