File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,6 @@ pub mod api;
7777pub mod r#async;
7878#[ cfg( feature = "blocking" ) ]
7979pub mod blocking;
80- #[ cfg( feature = "async" ) ]
8180pub mod sleeper;
8281
8382pub use api:: * ;
@@ -1014,25 +1013,25 @@ mod test {
10141013 assert_eq ! ( tx, tx_async) ;
10151014 }
10161015
1017- #[ cfg( feature = "tokio" ) ]
1016+ #[ cfg( all ( feature = "async" , feature = " tokio") ) ]
10181017 #[ test]
10191018 fn use_builder_with_tokio_as_normal ( ) {
10201019 let builder = Builder :: new ( "https://blockstream.info/testnet/api" ) ;
10211020 let client = builder. build_async ( ) ;
10221021 assert ! ( client. is_ok( ) ) ;
10231022 }
10241023
1025- #[ cfg( not( feature = "tokio" ) ) ]
1024+ #[ cfg( all ( feature = "async" , not( feature = "tokio" ) ) ) ]
10261025 struct TestRuntime ;
10271026
1028- #[ cfg( not( feature = "tokio" ) ) ]
1027+ #[ cfg( all ( feature = "async" , not( feature = "tokio" ) ) ) ]
10291028 impl Sleeper for TestRuntime {
10301029 async fn sleep ( duration : Duration ) {
10311030 tokio:: time:: sleep ( duration) . await ;
10321031 }
10331032 }
10341033
1035- #[ cfg( not( feature = "tokio" ) ) ]
1034+ #[ cfg( all ( feature = "async" , not( feature = "tokio" ) ) ) ]
10361035 #[ test]
10371036 fn use_with_custom_runtime ( ) {
10381037 let builder =
You can’t perform that action at this time.
0 commit comments