The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
style(tests): reorder imports and reformat assertion
Steven Enamakel6a949ce0917b
diff --git a/tests/saas_mode/cluster.rs b/tests/saas_mode/cluster.rsindex c0a106930e..174e38a8d6 100644--- a/tests/saas_mode/cluster.rs+++ b/tests/saas_mode/cluster.rs@@ -141,7 +141,7 @@ fn client() -> reqwest::blocking::Client {/// POST /rpc for `user` on `node`: status, `X-OpenHuman-Profile-Owner`, body.fn call(node: &Node, user: &str, method: &str, params: Value) -> (u16, Option<String>, Value) {- use openhuman_core::profiles::gateway::{USER_HEADER, USER_SIG_HEADER, sign};+ use openhuman_core::profiles::gateway::{sign, USER_HEADER, USER_SIG_HEADER};let response = client().post(format!("{}/rpc", node.base)).bearer_auth(BEARER)diff --git a/tests/saas_mode_e2e.rs b/tests/saas_mode_e2e.rsindex 27512c1a46..a5cc0ba29b 100644--- a/tests/saas_mode_e2e.rs+++ b/tests/saas_mode_e2e.rs@@ -8,7 +8,7 @@ use std::path::{Path, PathBuf};use std::process::{Child, Command, Stdio};use std::time::{Duration, Instant};-use serde_json::{Value, json};+use serde_json::{json, Value};#[path = "saas_mode/cluster.rs"]mod cluster;@@ -356,13 +356,12 @@ fn a_safe_deployment_serves_core_and_the_operator_plane_behind_the_gateway_beare"a user id outside the raw charset maps to its deterministic hash");assert!(!body.to_string().contains("alice"), "{body}");- assert!(- d.root- .join("users")- .join(&profile_id)- .join("workspace")- .is_dir()- );+ assert!(d+ .root+ .join("users")+ .join(&profile_id)+ .join("workspace")+ .is_dir());let (_, body) = rpc(&client, &base, Some(BEARER), "openhuman.profiles_list");assert!(body.to_string().contains(&profile_id), "{body}");@@ -439,7 +438,7 @@ fn user_rpc_with(method: &str,params: Value,) -> (u16, Value) {- use openhuman_core::profiles::gateway::{USER_HEADER, USER_SIG_HEADER, sign};+ use openhuman_core::profiles::gateway::{sign, USER_HEADER, USER_SIG_HEADER};let signature = sig.map(str::to_owned).unwrap_or_else(|| sign(BEARER, user, now()));@@ -538,7 +537,7 @@ fn gateway_requests_run_under_the_named_users_profile() {assert_eq!(status, 403, "bob is not provisioned: {body}");// A repeated signature header is refused, not resolved to the first value.{- use openhuman_core::profiles::gateway::{USER_HEADER, USER_SIG_HEADER, sign};+ use openhuman_core::profiles::gateway::{sign, USER_HEADER, USER_SIG_HEADER};let response = client.post(format!("{base}/rpc")).bearer_auth(BEARER)@@ -696,7 +695,7 @@ fn each_user_sees_only_their_own_threads() {/// Open `/events?client_id=` for `user` and forward each SSE `data:` line.fn user_events(base: &str, user: &str, client_id: &str) -> std::sync::mpsc::Receiver<String> {- use openhuman_core::profiles::gateway::{USER_HEADER, USER_SIG_HEADER, sign};+ use openhuman_core::profiles::gateway::{sign, USER_HEADER, USER_SIG_HEADER};use std::io::BufRead;let (tx, rx) = std::sync::mpsc::channel();let url = format!("{base}/events?client_id={client_id}");