Skip to content

Commit

Permalink
Update workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
survived committed Jun 3, 2024
1 parent 46951ac commit d50aa34
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 9 deletions.
16 changes: 9 additions & 7 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,29 +9,31 @@ env:
CARGO_NET_GIT_FETCH_WITH_CLI: true

jobs:
build-and-test:
check-and-test:
strategy:
matrix:
features: ["", "derive", "derive,alloc", "derive,std"]
features: ["", "derive", "derive,alloc", "derive,std", "digest", "digest,std"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: Swatinem/rust-cache@v2
with:
cache-on-failure: "true"
- name: Build
run: cargo build -p udigest --features "${{ matrix.features }}"
- name: Check
run: cargo check -p udigest --features "${{ matrix.features }}"
- name: Run tests
run: cargo test -p udigest --lib --tests --features "${{ matrix.features }}"
doctest:
test-all-features:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: Swatinem/rust-cache@v2
with:
cache-on-failure: "true"
- name: Doctests
run: cargo test --doc --all-features
- name: Check
run: cargo check -p udigest --all-features
- name: Run tests
run: cargo test -p udigest --all-features
run-examples:
runs-on: ubuntu-latest
steps:
Expand Down
8 changes: 6 additions & 2 deletions udigest/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,12 @@ digest = ["dep:digest"]

[[test]]
name = "derive"
required-features = ["std", "derive"]
required-features = ["std", "derive", "digest"]

[[example]]
name = "derivation"
required-features = ["std", "derive"]
required-features = ["std", "derive", "digest"]

[[test]]
name = "deterministic_hash"
required-features = ["derive", "digest"]

0 comments on commit d50aa34

Please sign in to comment.