CI: more accurate no-default-feature and nightly test targets
Also more accurate flags in examples
This commit is contained in:
parent
6a6b9fd06d
commit
22dec87aac
7
.github/workflows/test.yml
vendored
7
.github/workflows/test.yml
vendored
@ -73,14 +73,15 @@ jobs:
|
||||
- name: Maybe nightly
|
||||
if: ${{ matrix.toolchain == 'nightly' }}
|
||||
run: |
|
||||
cargo test --target ${{ matrix.target }} --tests --features=nightly
|
||||
cargo test --target ${{ matrix.target }} --features=nightly
|
||||
cargo test --target ${{ matrix.target }} --all-features
|
||||
cargo test --target ${{ matrix.target }} --benches --features=nightly
|
||||
cargo test --target ${{ matrix.target }} --manifest-path rand_distr/Cargo.toml --benches
|
||||
- name: Test rand
|
||||
run: |
|
||||
cargo test --target ${{ matrix.target }} --tests --no-default-features
|
||||
cargo test --target ${{ matrix.target }} --tests --no-default-features --features=alloc,getrandom,small_rng
|
||||
cargo test --target ${{ matrix.target }} --lib --tests --no-default-features
|
||||
cargo build --target ${{ matrix.target }} --no-default-features --features alloc,getrandom,small_rng
|
||||
cargo test --target ${{ matrix.target }} --lib --tests --no-default-features --features=alloc,getrandom,small_rng
|
||||
# all stable features:
|
||||
cargo test --target ${{ matrix.target }} --features=serde1,log,small_rng
|
||||
cargo test --target ${{ matrix.target }} --examples
|
||||
|
@ -24,7 +24,7 @@
|
||||
//! the square at random, calculate the fraction that fall within the circle,
|
||||
//! and multiply this fraction by 4.
|
||||
|
||||
#![cfg(feature = "std")]
|
||||
#![cfg(all(feature = "std", feature = "std_rng"))]
|
||||
|
||||
use rand::distributions::{Distribution, Uniform};
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
||||
//!
|
||||
//! [Monty Hall Problem]: https://en.wikipedia.org/wiki/Monty_Hall_problem
|
||||
|
||||
#![cfg(feature = "std")]
|
||||
#![cfg(all(feature = "std", feature = "std_rng"))]
|
||||
|
||||
use rand::distributions::{Distribution, Uniform};
|
||||
use rand::Rng;
|
||||
|
Loading…
x
Reference in New Issue
Block a user