From c1b132887ae9f7b9cce03c922a814abf50dd4e14 Mon Sep 17 00:00:00 2001 From: AurelienFT <32803821+AurelienFT@users.noreply.github.com> Date: Wed, 5 Jul 2023 16:35:50 +0200 Subject: [PATCH] Fix tests (#4221) * Deactivate stream_limiter Signed-off-by: Litchi Pi * Deactivate stream_limiter entirely Signed-off-by: Litchi Pi * fixup Signed-off-by: Litchi Pi * Add timeout on protocol and optimize operations verifications. * Update sandbox version * Remove imcompatibility * Add timeout of protocol in tests. * Fix tests without limiter --------- Signed-off-by: Litchi Pi Co-authored-by: Litchi Pi --- massa-bootstrap/src/tests/binders.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/massa-bootstrap/src/tests/binders.rs b/massa-bootstrap/src/tests/binders.rs index 05e87f770fe..dc5dd57b830 100644 --- a/massa-bootstrap/src/tests/binders.rs +++ b/massa-bootstrap/src/tests/binders.rs @@ -715,7 +715,7 @@ fn test_bandwidth() { _ => panic!("Bad message receive: Expected a peers list message"), } let dur = before.elapsed(); - assert!(dur > Duration::from_secs(9)); + //assert!(dur > Duration::from_secs(9)); assert!(dur < Duration::from_millis(millis_limit)); std::thread::sleep(Duration::from_secs(1)); @@ -727,7 +727,7 @@ fn test_bandwidth() { ) .unwrap(); let dur = before.elapsed(); - assert!(dur > Duration::from_secs(9), "{dur:?}"); + //assert!(dur > Duration::from_secs(9), "{dur:?}"); assert!(dur < Duration::from_millis(millis_limit)); } }) @@ -752,7 +752,7 @@ fn test_bandwidth() { ) .unwrap(); let dur = before.elapsed(); - assert!(dbg!(dur) > Duration::from_secs(9), "{dur:?}"); + //assert!(dbg!(dur) > Duration::from_secs(9), "{dur:?}"); assert!(dur < Duration::from_millis(millis_limit)); std::thread::sleep(Duration::from_secs(1)); @@ -765,7 +765,7 @@ fn test_bandwidth() { _ => panic!("Bad message receive: Expected a peers list message"), } let dur = before.elapsed(); - assert!(dur > Duration::from_secs(9)); + //assert!(dur > Duration::from_secs(9)); assert!(dur < Duration::from_millis(millis_limit)); } })