File tree 1 file changed +0
-21
lines changed
1 file changed +0
-21
lines changed Original file line number Diff line number Diff line change @@ -46,17 +46,6 @@ fn connect_error() {
46
46
}
47
47
}
48
48
49
- #[ test]
50
- fn connect_timeout_to_unreachable_address ( ) {
51
- let now = Instant :: now ( ) ;
52
- match TcpStream :: connect_timeout ( & format ! ( "1.1.1.1:9999" ) . parse ( ) . unwrap ( ) , Duration :: MAX ) {
53
- Ok ( ..) => panic ! ( "connected to an unreachable address, this is impossible" ) ,
54
- Err ( e) => assert_eq ! ( e. kind( ) , ErrorKind :: TimedOut ) ,
55
- }
56
-
57
- assert ! ( now. elapsed( ) > Duration :: from_secs( 20 ) ) ;
58
- }
59
-
60
49
#[ test]
61
50
#[ cfg_attr( target_env = "sgx" , ignore) ] // FIXME: https://github.com/fortanix/rust-sgx/issues/31
62
51
fn connect_timeout_error ( ) {
@@ -68,16 +57,6 @@ fn connect_timeout_error() {
68
57
assert ! ( TcpStream :: connect_timeout( & socket_addr, Duration :: MAX ) . is_ok( ) ) ;
69
58
}
70
59
71
- #[ test]
72
- fn connect_timeout_ok_bind ( ) {
73
- let listener = TcpListener :: bind ( "127.0.0.1:0" ) . unwrap ( ) ; // :0 picks some free port
74
- let port = listener. local_addr ( ) . unwrap ( ) . port ( ) ; // obtain the port it picked
75
- assert ! (
76
- TcpStream :: connect_timeout( & format!( "127.0.0.1:{port}" ) . parse( ) . unwrap( ) , Duration :: MAX )
77
- . is_ok( )
78
- ) ;
79
- }
80
-
81
60
#[ test]
82
61
fn listen_localhost ( ) {
83
62
let socket_addr = next_test_ip4 ( ) ;
You can’t perform that action at this time.
0 commit comments