Skip to content

Commit 9cbcfe4

Browse files
author
Chris Connelly
committed
Split all feature test invocation for MSRV and non-MSRV
Since const generics are not stable in Rust 1.36.0, we cannot use the `min_const_gen` feature when testing the MSRV.
1 parent cda0465 commit 9cbcfe4

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

.github/workflows/test.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,16 @@ jobs:
8282
cargo test --target ${{ matrix.target }} --lib --tests --no-default-features
8383
cargo build --target ${{ matrix.target }} --no-default-features --features alloc,getrandom,small_rng
8484
cargo test --target ${{ matrix.target }} --lib --tests --no-default-features --features=alloc,getrandom,small_rng
85-
# all stable features:
86-
cargo test --target ${{ matrix.target }} --features=serde1,log,small_rng,min_const_gen
8785
cargo test --target ${{ matrix.target }} --examples
86+
- name: Test rand (all stable features, non-MSRV)
87+
if: ${{ matrix.toolchain != '1.36.0' }}
88+
run: |
89+
cargo test --target ${{ matrix.target }} --features=serde1,log,small_rng,min_const_gen
90+
- name: Test rand (all stable features, MSRV)
91+
if: ${{ matrix.toolchain == '1.36.0' }}
92+
run: |
93+
# const generics are not stable on 1.36.0
94+
cargo test --target ${{ matrix.target }} --features=serde1,log,small_rng
8895
- name: Test rand_core
8996
run: |
9097
cargo test --target ${{ matrix.target }} --manifest-path rand_core/Cargo.toml

0 commit comments

Comments
 (0)