Commit 25dbeb71 authored by Thomas Daede's avatar Thomas Daede Committed by Thomas Daede
Browse files

Update to rand 0.5.

parent 61aa92ba
......@@ -12,7 +12,7 @@ repl = ["rustyline"]
bitstream-io = "0.6"
clap = "2"
libc = "0.2"
rand = "0.4"
rand = "0.5"
rustyline = { version = "1", optional = true }
y4m = "0.2"
enum-iterator-derive = "0.1.1"
......
......@@ -378,7 +378,7 @@ impl Intra for Block32x32 {}
#[cfg(test)]
pub mod test {
use super::*;
use rand::{ChaChaRng, Rng};
use rand::{ChaChaRng, Rng, SeedableRng};
const MAX_ITER: usize = 50000;
......@@ -581,7 +581,7 @@ pub mod test {
#[test]
fn pred_matches() {
let mut ra = ChaChaRng::new_unseeded();
let mut ra = ChaChaRng::from_seed([0; 32]);
for _ in 0..MAX_ITER {
let (o1, o2) = do_dc_pred(&mut ra);
assert_eq!(o1, o2);
......@@ -608,7 +608,7 @@ pub mod test {
#[test]
fn pred_same() {
let mut ra = ChaChaRng::new_unseeded();
let mut ra = ChaChaRng::from_seed([0; 32]);
for _ in 0..MAX_ITER {
let (_, o2) = do_dc_pred(&mut ra);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment