mirror of
https://github.com/fafhrd91/actix-net
synced 2024-12-18 06:53:11 +01:00
add delay to test
This commit is contained in:
parent
787255d030
commit
9887aef6e8
@ -102,6 +102,7 @@ fn test_start() {
|
|||||||
let _ = srv.pause();
|
let _ = srv.pause();
|
||||||
thread::sleep(time::Duration::from_millis(100));
|
thread::sleep(time::Duration::from_millis(100));
|
||||||
assert!(net::TcpStream::connect_timeout(&addr, time::Duration::from_millis(100)).is_ok());
|
assert!(net::TcpStream::connect_timeout(&addr, time::Duration::from_millis(100)).is_ok());
|
||||||
|
thread::sleep(time::Duration::from_millis(100));
|
||||||
assert!(net::TcpStream::connect_timeout(&addr, time::Duration::from_millis(100)).is_err());
|
assert!(net::TcpStream::connect_timeout(&addr, time::Duration::from_millis(100)).is_err());
|
||||||
|
|
||||||
// resume
|
// resume
|
||||||
|
Loading…
Reference in New Issue
Block a user