Skip to content

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

test: add test-only `prune` helper and remove unused assertion

Steven Enamakele052d629d27a
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
index b1fc0c8cb0..6bff5fc32a 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
@@ -195,6 +195,11 @@ pub(crate) fn cancel_all() -> Vec<String> {
thread_ids
}
+#[cfg(test)]
+pub(crate) fn prune(task_id: &str) {
+ let _ = registry().cancel_trusted(&TaskId::new(task_id));
+}
+
pub(crate) fn now_ms() -> u64 {
std::time::SystemTime::now()
.duration_since(std::time::UNIX_EPOCH)
diff --git a/crates/openhuman-core/src/inference/host_runtime/schemas_tests.rs b/crates/openhuman-core/src/inference/host_runtime/schemas_tests.rs
index ddf47a8f2b..948248ab3c 100644
--- a/crates/openhuman-core/src/inference/host_runtime/schemas_tests.rs
+++ b/crates/openhuman-core/src/inference/host_runtime/schemas_tests.rs
@@ -66,9 +66,6 @@ fn field_builder_helpers_are_correct_shape() {
let o = optional_string("k", "c");
assert!(!o.required);
- let ou = optional_u64("k", "c");
- assert!(!ou.required);
-
let j = json_output("result", "c");
assert!(j.required);
assert!(matches!(j.ty, TypeSchema::Json));