Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

test(storage): assert fenced error on stale queue ack

Steven Enamakelb4c97724cda8
diff --git a/crates/openhuman-core/src/storage/fenced_backend_tests.rs b/crates/openhuman-core/src/storage/fenced_backend_tests.rs
index 0453b95e2e..1d6cc7676b 100644
--- a/crates/openhuman-core/src/storage/fenced_backend_tests.rs
+++ b/crates/openhuman-core/src/storage/fenced_backend_tests.rs
@@ -228,7 +228,11 @@ async fn a_cached_handle_cannot_mutate_after_cross_process_takeover_on_any_port(
.await
.is_err());
assert!(storage.kv().put("key", json!(1)).await.is_err());
- assert!(!storage.queues().ack("work", &receipt).await.unwrap());
+ let error = storage.queues().ack("work", &receipt).await.unwrap_err();
+ assert!(matches!(
+ fence_error(&error),
+ Some(FenceError::Fenced { .. })
+ ));
let raw = shared
.backend