From 9264b837d897dcdf974703a6739132b995e669bc Mon Sep 17 00:00:00 2001 From: Mikail Bagishov Date: Sun, 31 May 2020 15:49:22 +0300 Subject: test: fix all clippy lints in tests (#2573) --- tokio/tests/macros_join.rs | 1 + tokio/tests/macros_select.rs | 1 + tokio/tests/macros_try_join.rs | 1 + tokio/tests/sync_mutex_owned.rs | 2 +- tokio/tests/time_delay_queue.rs | 1 + 5 files changed, 5 insertions(+), 1 deletion(-) (limited to 'tokio/tests') diff --git a/tokio/tests/macros_join.rs b/tokio/tests/macros_join.rs index d9b748d9..169e898f 100644 --- a/tokio/tests/macros_join.rs +++ b/tokio/tests/macros_join.rs @@ -1,3 +1,4 @@ +#![allow(clippy::blacklisted_name)] use tokio::sync::oneshot; use tokio_test::{assert_pending, assert_ready, task}; diff --git a/tokio/tests/macros_select.rs b/tokio/tests/macros_select.rs index c08e816a..6f027f3b 100644 --- a/tokio/tests/macros_select.rs +++ b/tokio/tests/macros_select.rs @@ -1,3 +1,4 @@ +#![allow(clippy::blacklisted_name)] use tokio::sync::{mpsc, oneshot}; use tokio::task; use tokio_test::{assert_ok, assert_pending, assert_ready}; diff --git a/tokio/tests/macros_try_join.rs b/tokio/tests/macros_try_join.rs index faa55421..a9251532 100644 --- a/tokio/tests/macros_try_join.rs +++ b/tokio/tests/macros_try_join.rs @@ -1,3 +1,4 @@ +#![allow(clippy::blacklisted_name)] use tokio::sync::oneshot; use tokio_test::{assert_pending, assert_ready, task}; diff --git a/tokio/tests/sync_mutex_owned.rs b/tokio/tests/sync_mutex_owned.rs index eef966fd..394a6708 100644 --- a/tokio/tests/sync_mutex_owned.rs +++ b/tokio/tests/sync_mutex_owned.rs @@ -36,7 +36,7 @@ fn straight_execution() { fn readiness() { let l = Arc::new(Mutex::new(100)); let mut t1 = spawn(l.clone().lock_owned()); - let mut t2 = spawn(l.clone().lock_owned()); + let mut t2 = spawn(l.lock_owned()); let g = assert_ready!(t1.poll()); diff --git a/tokio/tests/time_delay_queue.rs b/tokio/tests/time_delay_queue.rs index 3cf2d1cd..f04576d5 100644 --- a/tokio/tests/time_delay_queue.rs +++ b/tokio/tests/time_delay_queue.rs @@ -1,3 +1,4 @@ +#![allow(clippy::blacklisted_name)] #![warn(rust_2018_idioms)] #![cfg(feature = "full")] -- cgit v1.2.3