mirror of
https://github.com/actix/actix-extras.git
synced 2024-11-24 07:53:00 +01:00
flaky test
This commit is contained in:
parent
820404cdd2
commit
02b37570f4
@ -4,7 +4,7 @@ extern crate tokio_core;
|
|||||||
extern crate reqwest;
|
extern crate reqwest;
|
||||||
extern crate futures;
|
extern crate futures;
|
||||||
|
|
||||||
use std::{net, thread};
|
use std::{net, thread, time};
|
||||||
use std::sync::{Arc, mpsc};
|
use std::sync::{Arc, mpsc};
|
||||||
use std::sync::atomic::{AtomicUsize, Ordering};
|
use std::sync::atomic::{AtomicUsize, Ordering};
|
||||||
use futures::Future;
|
use futures::Future;
|
||||||
@ -34,6 +34,7 @@ fn test_start() {
|
|||||||
|
|
||||||
// pause
|
// pause
|
||||||
let _ = srv_addr.call_fut(dev::PauseServer).wait();
|
let _ = srv_addr.call_fut(dev::PauseServer).wait();
|
||||||
|
thread::sleep(time::Duration::from_millis(100));
|
||||||
assert!(net::TcpStream::connect(addr).is_err());
|
assert!(net::TcpStream::connect(addr).is_err());
|
||||||
|
|
||||||
// resume
|
// resume
|
||||||
|
Loading…
Reference in New Issue
Block a user