Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(iroh-net): increase timeout for local swarm discovery test #2574

Merged
merged 13 commits into from
Aug 3, 2024
7 changes: 4 additions & 3 deletions iroh-net/src/discovery/local_swarm_discovery.rs
Original file line number Diff line number Diff line change
Expand Up @@ -296,8 +296,8 @@ mod tests {
use testresult::TestResult;

#[tokio::test]
#[ignore = "flaky"]
async fn test_local_swarm_discovery() -> TestResult {
let _guard = iroh_test::logging::setup();
let (node_id_a, discovery_a) = make_discoverer()?;
let (_, discovery_b) = make_discoverer()?;

Expand All @@ -312,12 +312,13 @@ mod tests {
// resolve twice to ensure we can create separate streams for the same node_id
let mut s1 = discovery_b.resolve(ep.clone(), node_id_a).unwrap();
let mut s2 = discovery_b.resolve(ep, node_id_a).unwrap();
tracing::debug!(?node_id_a, "Discovering node id a");
// publish discovery_a's address
discovery_a.publish(&addr_info);
let s1_res = tokio::time::timeout(Duration::from_secs(5), s1.next())
let s1_res = tokio::time::timeout(Duration::from_secs(10), s1.next())
.await?
.unwrap()?;
let s2_res = tokio::time::timeout(Duration::from_secs(5), s2.next())
let s2_res = tokio::time::timeout(Duration::from_secs(10), s2.next())
.await?
.unwrap()?;
assert_eq!(s1_res.addr_info, addr_info);
Expand Down
Loading