Skip to content

Commit bb5a481

Browse files
committed
Try adding GitHub CI
1 parent a3bf7ac commit bb5a481

2 files changed

Lines changed: 60 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
env:
9+
CARGO_TERM_COLOR: always
10+
RUST_BACKTRACE: 1
11+
RUST_TOOLCHAIN: "1.96.0"
12+
13+
jobs:
14+
build-test:
15+
name: build + test (${{ matrix.os }})
16+
runs-on: ${{ matrix.os }}
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
os: [ubuntu-latest, macos-latest, windows-latest]
21+
steps:
22+
- uses: actions/checkout@v4
23+
- uses: dtolnay/rust-toolchain@master
24+
with:
25+
toolchain: ${{ env.RUST_TOOLCHAIN }}
26+
components: clippy, rustfmt
27+
- name: cargo fmt
28+
if: runner.os != 'Windows'
29+
run: cargo fmt --check
30+
- name: cargo clippy
31+
run: cargo clippy --all-targets -- -D warnings
32+
- name: cargo test
33+
run: cargo test
34+
- name: cargo build --release
35+
run: cargo build --release
36+
37+
slow-tests:
38+
name: slow tests (n_star = 127, 1023)
39+
runs-on: ubuntu-latest
40+
steps:
41+
- uses: actions/checkout@v4
42+
- uses: dtolnay/rust-toolchain@master
43+
with:
44+
toolchain: ${{ env.RUST_TOOLCHAIN }}
45+
- name: cargo test (slow, ignored)
46+
run: cargo test --release --test slow -- --ignored
47+
48+
doc:
49+
name: cargo doc
50+
runs-on: ubuntu-latest
51+
steps:
52+
- uses: actions/checkout@v4
53+
- uses: dtolnay/rust-toolchain@master
54+
with:
55+
toolchain: ${{ env.RUST_TOOLCHAIN }}
56+
- env:
57+
RUSTDOCFLAGS: -D warnings
58+
run: cargo doc --no-deps

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66

77
# Jevil
88

9+
[![CI](https://github.com/symbolicsoft/jevil/actions/workflows/ci.yml/badge.svg)](https://github.com/symbolicsoft/jevil/actions/workflows/ci.yml)
10+
911
> [!CAUTION]
1012
> ## ⚠️ EXPERIMENTAL — DO NOT USE IN PRODUCTION ⚠️
1113
>

0 commit comments

Comments
 (0)