Skip to content

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

chore: files changed crates/openhuman-core/src/cron/scheduler_announce_delivery_tests.rs

Steven Enamakel6febfe2d44f7
diff --git a/crates/openhuman-core/src/cron/scheduler_announce_delivery_tests.rs b/crates/openhuman-core/src/cron/scheduler_announce_delivery_tests.rs
index 6360f3dbb1..1f84a1f856 100644
--- a/crates/openhuman-core/src/cron/scheduler_announce_delivery_tests.rs
+++ b/crates/openhuman-core/src/cron/scheduler_announce_delivery_tests.rs
@@ -5,9 +5,11 @@ use tinychannels_bus::{Channel, ChannelMessage, SendMessage};
use tinyflows_bus::schedule::types::DeliveryStatus;
use tokio::sync::mpsc;
+type RecordedSends = Arc<Mutex<Vec<(String, Option<String>)>>>;
+
struct AnnounceMockChannel {
name: String,
- sends: Arc<Mutex<Vec<(String, Option<String>)>>>,
+ sends: RecordedSends,
fail: bool,
}
@@ -33,7 +35,7 @@ impl Channel for AnnounceMockChannel {
}
}
-fn install_mock_channel(name: String, fail: bool) -> Arc<Mutex<Vec<(String, Option<String>)>>> {
+fn install_mock_channel(name: String, fail: bool) -> RecordedSends {
let sends = Arc::new(Mutex::new(Vec::new()));
let channel: Arc<dyn Channel> = Arc::new(AnnounceMockChannel {
name: name.clone(),