Skip to content

Commit

Permalink
test: increase timeout for some tests
Browse files Browse the repository at this point in the history
We want tests to fail, rather than hanging forever, in situation where
we expect some incoming connection/message. Sadly, setting this timeout
is a bit arbitrary, and depending on the performance of the system
running the tests they could fire spuriously. That seems to be what
we're seeing in CI, so we're bumping the timeout to compensate.

Note that this will make some tests take longer, since the timeout is
also used to check that something we don't expect to happen, doesn't
happen.
  • Loading branch information
Chris Connelly authored and connec committed Oct 28, 2021
1 parent 398ecff commit ef2154d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/tests/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -822,6 +822,6 @@ trait Timeout: Sized {

impl<F: std::future::Future> Timeout for F {
fn timeout(self) -> tokio::time::Timeout<Self> {
tokio::time::timeout(Duration::from_secs(2), self)
tokio::time::timeout(Duration::from_secs(10), self)
}
}

0 comments on commit ef2154d

Please sign in to comment.