random test sometimes randomly fails
Some checks failed
Rust / build (pull_request) Failing after 1m4s

This commit is contained in:
Vinzenz Schroeter 2025-07-07 23:40:15 +02:00
parent 487dd03713
commit 3133dcceeb

View file

@ -106,10 +106,15 @@ mod tests {
#[cfg(feature = "rand")]
fn test() {
let mut rng = rand::rng();
// two so test failure is less likely
// more so random failure is less likely
assert_ne!(
[rng.random::<Brightness>(), rng.random()],
[rng.random(), rng.random()]
[
rng.random::<Brightness>(),
rng.random(),
rng.random(),
rng.random()
],
[rng.random(), rng.random(), rng.random(), rng.random()]
);
}
}