Skip to content

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

test(agent_harness): handle modules at top level in e2e assertion

Steven Enamakel3f22f7718d57
diff --git a/tests/agent_harness_e2e.rs b/tests/agent_harness_e2e.rs
index f7d0bc8570..8293f2d265 100644
--- a/tests/agent_harness_e2e.rs
+++ b/tests/agent_harness_e2e.rs
@@ -949,7 +949,8 @@ async fn managed_tinysearch_answer_reaches_followup_model_request_inner() {
post_json_rpc(&stack.rpc_base, 8_234, "openhuman.modules_list", json!({})).await;
let modules_response = assert_no_jsonrpc_error(&modules_response, "modules_list after search");
let tinysearch = modules_response
- .pointer("/result/modules")
+ .get("modules")
+ .or_else(|| modules_response.pointer("/result/modules"))
.and_then(Value::as_array)
.and_then(|modules| {
modules