From 8aee36a3ceb2ad9f3695c43b5ea5964a7630df1d Mon Sep 17 00:00:00 2001 From: Wez Furlong Date: Thu, 12 Dec 2024 07:16:48 -0700 Subject: [PATCH] throttle: increase tolerance in test cases refs: https://github.com/KumoCorp/kumomta/issues/297 --- crates/throttle/src/throttle.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/throttle/src/throttle.rs b/crates/throttle/src/throttle.rs index 0f0adb86..fb8aa4a8 100644 --- a/crates/throttle/src/throttle.rs +++ b/crates/throttle/src/throttle.rs @@ -337,7 +337,7 @@ mod test { #[tokio::test] async fn basic_throttle_60_000() { - test_big_limits(60_000, Some(100), 0.05, &*MEMORY).await; + test_big_limits(60_000, Some(100), 0.1, &*MEMORY).await; } #[tokio::test] @@ -345,7 +345,7 @@ mod test { // Note that the 5% tolerance here is the same as the basic_throttle_60_000 // test case because the variance is due to timing issues with very small // time periods produced by the overally limit, rather than the burst. - test_big_limits(60_000, Some(100), 0.05, &*MEMORY).await; + test_big_limits(60_000, Some(100), 0.1, &*MEMORY).await; } #[tokio::test]