From bfe04ea56f0ecd2036553306f1858def20d30b2d Mon Sep 17 00:00:00 2001 From: DaniPopes <57450786+DaniPopes@users.noreply.github.com> Date: Mon, 6 Jan 2025 16:03:29 +0100 Subject: [PATCH] test: fix warnings on windows (#1895) --- crates/provider/src/ext/debug.rs | 2 +- crates/provider/src/ext/trace.rs | 4 ++-- crates/provider/src/provider/trait.rs | 6 ++++-- crates/rpc-client/src/builtin.rs | 3 ++- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/crates/provider/src/ext/debug.rs b/crates/provider/src/ext/debug.rs index 5bf2bd8e7be..dfeb1bc0884 100644 --- a/crates/provider/src/ext/debug.rs +++ b/crates/provider/src/ext/debug.rs @@ -537,7 +537,7 @@ mod test { } #[tokio::test] - #[cfg(not(windows))] + #[cfg_attr(windows, ignore)] async fn debug_trace_call_many() { async_ci_only(|| async move { run_with_tempdir("reth-test-", |temp_dir| async move { diff --git a/crates/provider/src/ext/trace.rs b/crates/provider/src/ext/trace.rs index 58c7a268fc1..7b336431beb 100644 --- a/crates/provider/src/ext/trace.rs +++ b/crates/provider/src/ext/trace.rs @@ -189,7 +189,7 @@ mod test { } #[tokio::test] - #[cfg(not(windows))] + #[cfg_attr(windows, ignore)] async fn trace_call() { async_ci_only(|| async move { run_with_tempdir("reth-test-", |temp_dir| async move { @@ -241,7 +241,7 @@ mod test { } #[tokio::test] - #[cfg(not(windows))] + #[cfg_attr(windows, ignore)] async fn trace_call_many() { async_ci_only(|| async move { run_with_tempdir("reth-test-", |temp_dir| async move { diff --git a/crates/provider/src/provider/trait.rs b/crates/provider/src/provider/trait.rs index d9ce8ee41d4..46b419b379a 100644 --- a/crates/provider/src/provider/trait.rs +++ b/crates/provider/src/provider/trait.rs @@ -1255,8 +1255,9 @@ mod tests { assert_eq!(0, num); } - #[cfg(all(feature = "hyper", not(windows)))] + #[cfg(feature = "hyper")] #[tokio::test] + #[cfg_attr(windows, ignore)] async fn test_auth_layer_transport() { crate::ext::test::async_ci_only(|| async move { use alloy_node_bindings::Reth; @@ -1341,8 +1342,9 @@ mod tests { } } - #[cfg(all(feature = "ws", not(windows)))] + #[cfg(feature = "ws")] #[tokio::test] + #[cfg_attr(windows, ignore)] async fn subscribe_blocks_ws() { use futures::stream::StreamExt; diff --git a/crates/rpc-client/src/builtin.rs b/crates/rpc-client/src/builtin.rs index 0473b2e7caf..d8dafed1982 100644 --- a/crates/rpc-client/src/builtin.rs +++ b/crates/rpc-client/src/builtin.rs @@ -250,7 +250,8 @@ mod test { } #[test] - #[cfg(all(feature = "ipc", not(windows)))] + #[cfg(feature = "ipc")] + #[cfg_attr(windows, ignore)] fn test_parsing_ipc() { use alloy_node_bindings::Anvil;