diff options
Diffstat (limited to 'src/tests/fakes/fake_input.rs')
-rw-r--r-- | src/tests/fakes/fake_input.rs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/tests/fakes/fake_input.rs b/src/tests/fakes/fake_input.rs index 889e708..b3b089b 100644 --- a/src/tests/fakes/fake_input.rs +++ b/src/tests/fakes/fake_input.rs @@ -10,9 +10,12 @@ use ::std::task::{Context, Poll}; use ::std::{thread, time}; use ::termion::event::Event; -use crate::network::{ - dns::{self, Lookup}, - Connection, Protocol, +use crate::{ + network::{ + dns::{self, Lookup}, + Connection, Protocol, + }, + os::OnSigWinch, }; pub struct KeyboardEvents { @@ -142,7 +145,7 @@ pub fn get_interface() -> NetworkInterface { } } -pub fn create_fake_on_winch(should_send_winch_event: bool) -> Box<dyn Fn(Box<dyn Fn()>) + Send> { +pub fn create_fake_on_winch(should_send_winch_event: bool) -> Box<OnSigWinch> { Box::new(move |cb| { if should_send_winch_event { thread::sleep(time::Duration::from_millis(900)); |