diff --git a/rust/Cargo.toml b/rust/Cargo.toml index a55e21aa0..d105a3649 100644 --- a/rust/Cargo.toml +++ b/rust/Cargo.toml @@ -21,7 +21,7 @@ regex = "1.10.4" tokio = { version = "1.37", features = ["sync", "fs"] } sha2 = "0.10.8" futures = "0.3.30" -rand = "0.8.5" +rand = "0.9.0" async-trait = "0.1.80" bytes = "1.6.0" tokio-util = "0.7.11" diff --git a/rust/tests/real_api_integration_tests.rs b/rust/tests/real_api_integration_tests.rs index 0824e3ad5..e5addc00c 100644 --- a/rust/tests/real_api_integration_tests.rs +++ b/rust/tests/real_api_integration_tests.rs @@ -1,5 +1,6 @@ use futures::future::try_join_all; -use rand::{distributions::Alphanumeric, Rng}; +use rand::distr::Alphanumeric; +use rand::Rng; use reqwest::Url; use std::convert::TryFrom; use std::ops::Deref; @@ -426,7 +427,7 @@ async fn from_file_single_clean_file() { #[tokio::test] async fn from_file_single_unknown_file() { - let unknown: String = rand::thread_rng() + let unknown: String = rand::rng() .sample_iter(&Alphanumeric) .take(50) .map(char::from) @@ -449,12 +450,12 @@ async fn from_file_single_unknown_file() { #[tokio::test] async fn from_files_unknown_files() { - let unknown1: String = rand::thread_rng() + let unknown1: String = rand::rng() .sample_iter(&Alphanumeric) .take(50) .map(char::from) .collect(); - let unknown2: String = rand::thread_rng() + let unknown2: String = rand::rng() .sample_iter(&Alphanumeric) .take(50) .map(char::from)