Skip to content

Commit

Permalink
Fix flaky max_response_size_exceeded test
Browse files Browse the repository at this point in the history
  • Loading branch information
nazar-pc committed Dec 13, 2024
1 parent cd01e42 commit 41fed42
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions substrate/client/network/src/request_responses.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1115,7 +1115,7 @@ mod tests {
SwarmConfig::with_executor(TokioExecutor(runtime))
// This is taken care of by notification protocols in non-test environment
// It is very slow in test environment for some reason, hence larger timeout
.with_idle_connection_timeout(Duration::from_secs(300)),
.with_idle_connection_timeout(Duration::from_secs(10)),
);

let listen_addr: Multiaddr = format!("/memory/{}", rand::random::<u64>()).parse().unwrap();
Expand Down Expand Up @@ -1285,7 +1285,9 @@ mod tests {
match swarm.select_next_some().await {
SwarmEvent::Behaviour(Event::InboundRequest { result, .. }) => {
assert!(result.is_ok());
break
},
SwarmEvent::ConnectionClosed { .. } => {
break;
},
_ => {},
}
Expand Down

0 comments on commit 41fed42

Please sign in to comment.