test(client): fix pool tests compilation errors
This commit is contained in:
@@ -831,10 +831,11 @@ mod tests {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn pool_max_idle_no_timer<T>(max_idle: usize) -> Pool<T> {
|
fn pool_max_idle_no_timer<T>(max_idle: usize) -> Pool<T> {
|
||||||
let pool = Pool::new(
|
let pool = Pool::new(super::Config {
|
||||||
super::Enabled(true),
|
enabled: true,
|
||||||
super::IdleTimeout(Some(Duration::from_millis(100))),
|
keep_alive_timeout: Some(Duration::from_millis(100)),
|
||||||
super::MaxIdlePerHost(max_idle),
|
max_idle_per_host: max_idle,
|
||||||
|
},
|
||||||
&Exec::Default,
|
&Exec::Default,
|
||||||
);
|
);
|
||||||
pool.no_timer();
|
pool.no_timer();
|
||||||
@@ -912,10 +913,11 @@ mod tests {
|
|||||||
use std::time::Instant;
|
use std::time::Instant;
|
||||||
use tokio_timer::Delay;
|
use tokio_timer::Delay;
|
||||||
let mut rt = ::tokio::runtime::current_thread::Runtime::new().unwrap();
|
let mut rt = ::tokio::runtime::current_thread::Runtime::new().unwrap();
|
||||||
let pool = Pool::new(
|
let pool = Pool::new(super::Config {
|
||||||
super::Enabled(true),
|
enabled: true,
|
||||||
super::IdleTimeout(Some(Duration::from_millis(100))),
|
keep_alive_timeout: Some(Duration::from_millis(100)),
|
||||||
super::MaxIdlePerHost(::std::usize::MAX),
|
max_idle_per_host: ::std::usize::MAX,
|
||||||
|
},
|
||||||
&Exec::Default,
|
&Exec::Default,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user