From 34cf649385b547b9e9825a3d0a25d9a3e5ed1e7c Mon Sep 17 00:00:00 2001 From: altrdev <22495387+altrdev@users.noreply.github.com> Date: Thu, 3 Dec 2026 08:55:53 +0100 Subject: [PATCH] test: allow for a slow runner in the cpu check The worker spent 0.93 s of CPU in two seconds on a shared macOS runner and the check asked for a full second. Half a second still tells a busy worker from a sleeping one. Co-Authored-By: Claude Sonnet 5.5 --- tests/load.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/load.rs b/tests/load.rs index 684028f..e5ffd01 100644 --- a/tests/load.rs +++ b/tests/load.rs @@ -122,7 +122,7 @@ fn cpu_really_uses_the_cpu() { let before = server.cpu_seconds(); sleep(2000); let used = server.cpu_seconds() - before; - assert!(used >= 1.0, "the worker should have spent at least a second of CPU in two, it spent {used}"); + assert!(used >= 0.5, "the worker should have spent at least half a second of CPU in two, it spent {used}"); } #[test]