Skip to content

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

style(composio): reformat test assertions and drop trailing blank line

Steven Enamakelb0e039611739
diff --git a/crates/openhuman-core/src/integrations/composio/ops/scope_prefs_tests.rs b/crates/openhuman-core/src/integrations/composio/ops/scope_prefs_tests.rs
index 8ff3fc8eef..a54be8028f 100644
--- a/crates/openhuman-core/src/integrations/composio/ops/scope_prefs_tests.rs
+++ b/crates/openhuman-core/src/integrations/composio/ops/scope_prefs_tests.rs
@@ -22,7 +22,11 @@ fn wire_conversion_round_trips_every_flag() {
#[test]
fn row_key_normalises_the_toolkit() {
assert_eq!(UserScopePref::key(" GitHub "), "github");
- assert_eq!(UserScopePref::key(" "), "", "an all-whitespace toolkit has no row");
+ assert_eq!(
+ UserScopePref::key(" "),
+ "",
+ "an all-whitespace toolkit has no row"
+ );
}
#[tokio::test]
@@ -45,12 +49,13 @@ async fn legacy_prefs_stay_on_disk_until_the_module_takes_them() {
std::fs::write(&path, legacy).unwrap();
let pref = load_or_default(&config, "github").await;
- assert_eq!(pref, UserScopePref::default(), "unreachable module fails open");
+ assert_eq!(
+ pref,
+ UserScopePref::default(),
+ "unreachable module fails open"
+ );
assert_eq!(std::fs::read_to_string(&path).unwrap(), legacy);
- assert!(!migrated()
- .lock()
- .unwrap()
- .contains(&config.workspace_dir));
+ assert!(!migrated().lock().unwrap().contains(&config.workspace_dir));
}
#[tokio::test]
@@ -70,8 +75,5 @@ async fn a_workspace_with_no_legacy_file_is_marked_migrated() {
let dir = tempfile::tempdir().unwrap();
let config = config_in(&dir);
migrate_legacy(&config).await;
- assert!(migrated()
- .lock()
- .unwrap()
- .contains(&config.workspace_dir));
+ assert!(migrated().lock().unwrap().contains(&config.workspace_dir));
}
diff --git a/crates/openhuman-core/src/integrations/composio/tools/render.rs b/crates/openhuman-core/src/integrations/composio/tools/render.rs
index e239a05fdf..25aa445f78 100644
--- a/crates/openhuman-core/src/integrations/composio/tools/render.rs
+++ b/crates/openhuman-core/src/integrations/composio/tools/render.rs
@@ -164,4 +164,3 @@ pub(super) fn render_tools_markdown(resp: &super::super::types::ComposioToolsRes
}
out
}
-
diff --git a/crates/openhuman-core/src/integrations/composio/tools/scope_gate_tests.rs b/crates/openhuman-core/src/integrations/composio/tools/scope_gate_tests.rs
index 610b5568ae..ede4643849 100644
--- a/crates/openhuman-core/src/integrations/composio/tools/scope_gate_tests.rs
+++ b/crates/openhuman-core/src/integrations/composio/tools/scope_gate_tests.rs
@@ -25,9 +25,17 @@ fn an_action_outside_a_curated_catalog_is_not_curated() {
#[test]
fn an_uncatalogued_toolkit_falls_back_to_the_verb_heuristic() {
- let read = decide_visibility("flowstestkit", "FLOWSTESTKIT_GET_THING", only(true, false, false));
+ let read = decide_visibility(
+ "flowstestkit",
+ "FLOWSTESTKIT_GET_THING",
+ only(true, false, false),
+ );
assert!(matches!(read, ToolDecision::PassthroughCheckScope { .. }));
- let admin = decide_visibility("flowstestkit", "FLOWSTESTKIT_DELETE_THING", only(true, true, false));
+ let admin = decide_visibility(
+ "flowstestkit",
+ "FLOWSTESTKIT_DELETE_THING",
+ only(true, true, false),
+ );
assert!(matches!(
admin,
ToolDecision::BlockedByScope {
@@ -44,7 +52,11 @@ fn unknown_slugs_default_to_write_for_the_sandbox_gate() {
#[test]
fn the_scope_error_names_the_toolkit_and_the_unlock_path() {
- let message = scope_error_message("GMAIL_SEND_EMAIL", ToolScope::Write, only(true, false, false));
+ let message = scope_error_message(
+ "GMAIL_SEND_EMAIL",
+ ToolScope::Write,
+ only(true, false, false),
+ );
assert!(message.contains("Connections → gmail → write"), "{message}");
assert!(message.contains("write=false"), "{message}");
}