From 7af44ae591e9c4f54d4ccaa76310f5dbe39d0c9e Mon Sep 17 00:00:00 2001 From: Solomon Jacobs Date: Thu, 7 Nov 2024 17:45:10 +0100 Subject: [PATCH] test: terminate scheduler on timeout CMK-20046 --- tests/test_scheduler.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/test_scheduler.rs b/tests/test_scheduler.rs index 4786a67b..699113f7 100644 --- a/tests/test_scheduler.rs +++ b/tests/test_scheduler.rs @@ -358,6 +358,9 @@ async fn run_scheduler( bail!("Scheduler terminated unexpectedly") }, _ = sleep(Duration::from_secs(n_seconds_run_max)) => { + if let Err(e) = remove_file(&run_flag_path) { + eprintln!("Removing run file failed: {e}"); + } bail!(format!("Not all plan result files appeared within {n_seconds_run_max} seconds")) }, };