testing tests

This commit is contained in:
kozabrada123 2024-01-18 17:10:07 +01:00
parent 453377924e
commit 54f7136a58
1 changed files with 3 additions and 1 deletions

View File

@ -61,9 +61,11 @@ async fn test_gateway_authenticate() {
gateway.send_identify(identify).await; gateway.send_identify(identify).await;
let current_time = std::time::Instant::now();
tokio::select! { tokio::select! {
// Fail, we timed out waiting for it // Fail, we timed out waiting for it
() = safina_timer::sleep_for(Duration::from_secs(20)) => { () = safina_timer::sleep_until(current_time + Duration::from_secs(20)) => {
println!("Timed out waiting for event, failing.."); println!("Timed out waiting for event, failing..");
assert!(false); assert!(false);
} }