Skip to content

Commit

Permalink
chore: add test files
Browse files Browse the repository at this point in the history
This branch is meant to test the template.
  • Loading branch information
clechasseur committed Sep 16, 2024
1 parent 727af3e commit fcbcc6c
Show file tree
Hide file tree
Showing 10 changed files with 2,072 additions and 14 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/audit-check.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: Security audit

on:
# TODO re-enable once project is set up properly
#push:
push:
#schedule:
# - cron: '0 0 * * *'
workflow_dispatch:
Expand Down
28 changes: 16 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: CI

on:
# TODO re-enable once project is set up properly
#push:
push:
workflow_dispatch:

env:
Expand All @@ -14,7 +13,7 @@ jobs:
strategy:
fail-fast: false
matrix:
all-features: [ false ] # TODO if your crate has optional features, add 'true' to this list
all-features: [ false, true ]
runs-on: ubuntu-latest
steps:
- name: Checkout code
Expand Down Expand Up @@ -55,9 +54,9 @@ jobs:
strategy:
fail-fast: false
matrix:
toolchain: [ 1.60.0 ] # TODO: change for your minimum supported Rust version
toolchain: [ 1.70.0 ]
os: [ ubuntu, macos, windows ]
all-features: [ false ] # TODO if your crate has optional features, add 'true' to this list
all-features: [ false, true ]
runs-on: ${{ matrix.os }}-latest
steps:
- name: Checkout code
Expand Down Expand Up @@ -87,6 +86,8 @@ jobs:
uses: taiki-e/install-action@ae888b48c8777229768754549e5463ba726cb1b3 # v2.44.1
with:
tool: just,cargo-hack,cargo-minimal-versions,cargo-msrv-prep
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Run checks using cargo-minimal-versions
run: just all_features=${{ matrix.all-features }} check-minimal
Expand All @@ -96,18 +97,18 @@ jobs:
strategy:
fail-fast: false
matrix:
toolchain: [ 1.68.2, stable, beta, nightly ] # TODO: change 1.68.2 for your minimum supported Rust version
toolchain: [ 1.75.0, stable, beta, nightly ]
os: [ ubuntu, macos, windows ]
ignore-lock: [ false, true ]
all-features: [ false ] # TODO if your crate has optional features, add 'true' to this list
all-features: [ false, true ]
include:
- experimental: false
- toolchain: beta
experimental: true
- toolchain: nightly
experimental: true
exclude:
- toolchain: 1.68.2 # TODO: change this version to match the minimum supported Rust version specified above
- toolchain: 1.75.0
ignore-lock: true
runs-on: ${{ matrix.os }}-latest
continue-on-error: ${{ matrix.experimental }}
Expand Down Expand Up @@ -137,6 +138,8 @@ jobs:
uses: taiki-e/install-action@ae888b48c8777229768754549e5463ba726cb1b3 # v2.44.1
with:
tool: just
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Run checks
run: just all_features=${{ matrix.all-features }} check
Expand All @@ -145,9 +148,6 @@ jobs:
run: just all_features=${{ matrix.all-features }} test

tarpaulin:
# Note: there seems to be an issue in `cargo-tarpaulin` when using Rust 1.75.0 or later - it reports some missing line coverage.
# I've entered an issue: https://github.com/xd009642/tarpaulin/issues/1438
# In the meantime, let's pin the Rust version used for code coverage to 1.74.1 until we know what's happening.
name: Code coverage
runs-on: ubuntu-latest
steps:
Expand All @@ -157,7 +157,7 @@ jobs:
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@1fbea72663f6d4c03efaab13560c8a24cfd2a7cc # v1.9.0
with:
toolchain: 1.74.1
toolchain: 1.75.0
cache: false

- name: Rust Cache
Expand All @@ -171,6 +171,8 @@ jobs:
uses: taiki-e/install-action@ae888b48c8777229768754549e5463ba726cb1b3 # v2.44.1
with:
tool: cargo-tarpaulin
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Run cargo-tarpaulin
uses: clechasseur/rs-cargo@34eb9ee3e4186e5c7820a54393fbf081f78bc102 # v2.0.5
Expand Down Expand Up @@ -225,6 +227,8 @@ jobs:
uses: taiki-e/install-action@ae888b48c8777229768754549e5463ba726cb1b3 # v2.44.1
with:
tool: just
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Generate doc using rustdoc
run: just doc
Expand Down
Loading

0 comments on commit fcbcc6c

Please sign in to comment.