diff options
| author | bors <bors@rust-lang.org> | 2019-04-17 10:03:02 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2019-04-17 10:03:02 +0000 |
| commit | efe2f32a6b8217425f361ec7c206910c611c03ee (patch) | |
| tree | 8976b59372367993066cd5d3bdd70f8b50e7aa81 /src/liballoc | |
| parent | e4e032a0ae82d7db4f99872ff98626af2941c4a5 (diff) | |
| parent | eb958e1b2e498f4751ac7c36cb2aeb4ce2ab68a0 (diff) | |
| download | rust-efe2f32a6b8217425f361ec7c206910c611c03ee.tar.gz rust-efe2f32a6b8217425f361ec7c206910c611c03ee.zip | |
Auto merge of #60030 - Centril:rollup-3d0t24t, r=Centril
Rollup of 5 pull requests Successful merges: - #59128 (Emit ansi color codes in the `rendered` field of json diagnostics) - #59646 (const fn: Improve wording) - #59986 (Miri: refactor new allocation tagging) - #60003 (LLD is not supported on Darwin) - #60018 (Miri now supports entropy, but is still slow) Failed merges: r? @ghost
Diffstat (limited to 'src/liballoc')
| -rw-r--r-- | src/liballoc/tests/binary_heap.rs | 2 | ||||
| -rw-r--r-- | src/liballoc/tests/slice.rs | 21 |
2 files changed, 16 insertions, 7 deletions
diff --git a/src/liballoc/tests/binary_heap.rs b/src/liballoc/tests/binary_heap.rs index 0930f8dacd4..0685fa943c0 100644 --- a/src/liballoc/tests/binary_heap.rs +++ b/src/liballoc/tests/binary_heap.rs @@ -282,7 +282,7 @@ fn assert_covariance() { // // Destructors must be called exactly once per element. #[test] -#[cfg(not(miri))] // Miri does not support panics nor entropy +#[cfg(not(miri))] // Miri does not support catching panics fn panic_safe() { static DROP_COUNTER: AtomicUsize = AtomicUsize::new(0); diff --git a/src/liballoc/tests/slice.rs b/src/liballoc/tests/slice.rs index b54c128a024..ad2cd7c95eb 100644 --- a/src/liballoc/tests/slice.rs +++ b/src/liballoc/tests/slice.rs @@ -389,7 +389,7 @@ fn test_reverse() { } #[test] -#[cfg(not(miri))] // Miri does not support entropy +#[cfg(not(miri))] // Miri is too slow fn test_sort() { let mut rng = thread_rng(); @@ -466,10 +466,19 @@ fn test_sort() { } #[test] -#[cfg(not(miri))] // Miri does not support entropy fn test_sort_stability() { - for len in (2..25).chain(500..510) { - for _ in 0..10 { + #[cfg(not(miri))] // Miri is too slow + let large_range = 500..510; + #[cfg(not(miri))] // Miri is too slow + let rounds = 10; + + #[cfg(miri)] + let large_range = 0..0; // empty range + #[cfg(miri)] + let rounds = 1; + + for len in (2..25).chain(large_range) { + for _ in 0..rounds { let mut counts = [0; 10]; // create a vector like [(6, 1), (5, 1), (6, 2), ...], @@ -1397,7 +1406,7 @@ fn test_box_slice_clone() { #[test] #[allow(unused_must_use)] // here, we care about the side effects of `.clone()` #[cfg_attr(target_os = "emscripten", ignore)] -#[cfg(not(miri))] // Miri does not support threads nor entropy +#[cfg(not(miri))] // Miri does not support threads fn test_box_slice_clone_panics() { use std::sync::Arc; use std::sync::atomic::{AtomicUsize, Ordering}; @@ -1589,7 +1598,7 @@ thread_local!(static SILENCE_PANIC: Cell<bool> = Cell::new(false)); #[test] #[cfg_attr(target_os = "emscripten", ignore)] // no threads -#[cfg(not(miri))] // Miri does not support threads nor entropy +#[cfg(not(miri))] // Miri does not support threads fn panic_safe() { let prev = panic::take_hook(); panic::set_hook(Box::new(move |info| { |
