Skip to content

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

test(tools): add type aliases for schema contract tables

Steven Enamakel1ae7e0c287af
diff --git a/crates/openhuman-core/src/tools/schemas_tests.rs b/crates/openhuman-core/src/tools/schemas_tests.rs
index add77715fe..d0e0e011f8 100644
--- a/crates/openhuman-core/src/tools/schemas_tests.rs
+++ b/crates/openhuman-core/src/tools/schemas_tests.rs
@@ -8,6 +8,9 @@ use crate::tools::schemas::registry::tools_schemas;
use serde_json::{json, Map};
const BASE_CONTROLLERS: usize = 5;
+type InputContract = (&'static str, Option<bool>);
+type ToolSchemaContract = (&'static str, &'static [InputContract]);
+
#[test]
fn all_schemas_covers_the_base_surface() {
assert_eq!(all_controller_schemas().len(), BASE_CONTROLLERS);
@@ -38,7 +41,7 @@ fn tools_schema_wire_contracts_are_preserved() {
&all_registered_controllers(),
"web_search",
);
- let contracts: &[(&str, &[(&str, Option<bool>)])] = &[
+ let contracts: &[ToolSchemaContract] = &[
("composio_execute", &[("action", Some(true))]),
("web_answer", &[("query", Some(true)), ("depth", None)]),
("web_contents", &[("urls", Some(true))]),