From ceca7c502057fedee2e77329df4ec23b1bebaa03 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Tue, 16 Apr 2019 19:06:08 +0200 Subject: [PATCH] tweak entropy tests a bit --- tests/compile-fail/getrandom.rs | 4 ++-- tests/run-pass/hashmap.rs | 9 +++++---- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/compile-fail/getrandom.rs b/tests/compile-fail/getrandom.rs index 4dc3e863aaa..d54c95c8238 100644 --- a/tests/compile-fail/getrandom.rs +++ b/tests/compile-fail/getrandom.rs @@ -1,5 +1,5 @@ -// ignore-macos -// ignore-windows +// ignore-macos: Uses Linux-only APIs +// ignore-windows: Uses Linux-only APIs #![feature(rustc_private)] extern crate libc; diff --git a/tests/run-pass/hashmap.rs b/tests/run-pass/hashmap.rs index b29b6819397..796e63c81a4 100644 --- a/tests/run-pass/hashmap.rs +++ b/tests/run-pass/hashmap.rs @@ -27,12 +27,13 @@ fn test_map(mut map: HashMap) { } fn main() { - // TODO: Implement random number generation on OS X if cfg!(not(target_os = "macos")) { - let map_normal: HashMap = HashMap::new(); - test_map(map_normal); + let map: HashMap = HashMap::default(); + test_map(map); } else { - let map : HashMap> = Default::default(); + // TODO: Implement random number generation on OS X. + // Until then, use a deterministic map. + let map : HashMap> = HashMap::default(); test_map(map); } } -- 2.44.0