| 134 | |
| 135 | #[tokio::test] |
| 136 | async fn test_https() { |
| 137 | let provider = Web3::new_from_url("https://rpc.mevblocker.io"); |
| 138 | let response = provider.provider.get_block(BlockId::latest()).await; |
| 139 | |
| 140 | if let Err(err) = response { |
| 141 | // only fail the CI if we are sure the error is due to missing |
| 142 | // `https` support |
| 143 | if err.to_string().contains("scheme is not http") { |
| 144 | eprintln!("{err:?}"); |
| 145 | panic!("https support is not enabled"); |
| 146 | } else { |
| 147 | eprintln!("mevblocker error unrelated to https support: {err:?}"); |
| 148 | } |
| 149 | } |
| 150 | } |
| 151 | } |