Skip to content

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

style: apply rustfmt formatting across cli and test modules

Steven Enamakel62293c6cf39e
diff --git a/crates/openhuman-core/src/core/cli.rs b/crates/openhuman-core/src/core/cli.rs
index c8d01385ca..2dd702a21a 100644
--- a/crates/openhuman-core/src/core/cli.rs
+++ b/crates/openhuman-core/src/core/cli.rs
@@ -411,11 +411,8 @@ fn parse_serve_args(
}
}
- let (mode, saas_config) = crate::core::server_launcher::resolve_mode(
- mode_flag.as_deref(),
- env_mode,
- saas_config,
- )?;
+ let (mode, saas_config) =
+ crate::core::server_launcher::resolve_mode(mode_flag.as_deref(), env_mode, saas_config)?;
Ok(Some((
crate::core::server_launcher::ServeRequest {
host,
diff --git a/crates/openhuman-core/src/core/cli_tests.rs b/crates/openhuman-core/src/core/cli_tests.rs
index d9748ddc2e..ae565580dc 100644
--- a/crates/openhuman-core/src/core/cli_tests.rs
+++ b/crates/openhuman-core/src/core/cli_tests.rs
@@ -361,7 +361,14 @@ fn serve_args_without_flags_leave_every_override_unset() {
fn serve_args_flags_are_explicit_overrides_on_top_of_the_host_boot() {
let boot = crate::core::server_launcher::HostBoot::new(1u8);
let (request, verbose) = parse_serve_args(
- &strings(&["--port", "7801", "--host", "0.0.0.0", "--jsonrpc-only", "-v"]),
+ &strings(&[
+ "--port",
+ "7801",
+ "--host",
+ "0.0.0.0",
+ "--jsonrpc-only",
+ "-v",
+ ]),
None,
Some(boot.clone()),
)
diff --git a/crates/openhuman-core/src/core/server_launcher_tests.rs b/crates/openhuman-core/src/core/server_launcher_tests.rs
index d09cdb7a94..da6c8ef528 100644
--- a/crates/openhuman-core/src/core/server_launcher_tests.rs
+++ b/crates/openhuman-core/src/core/server_launcher_tests.rs
@@ -77,5 +77,9 @@ fn host_boot_hands_a_value_over_once() {
fn host_boot_keeps_the_value_when_the_type_does_not_match() {
let boot = HostBoot::new(7u32);
assert!(boot.take::<String>().is_none());
- assert_eq!(boot.take::<u32>(), Some(7), "a wrong guess does not consume it");
+ assert_eq!(
+ boot.take::<u32>(),
+ Some(7),
+ "a wrong guess does not consume it"
+ );
}
diff --git a/crates/openhuman-rpc/src/server/cli.rs b/crates/openhuman-rpc/src/server/cli.rs
index f8171f7962..14719dfe0d 100644
--- a/crates/openhuman-rpc/src/server/cli.rs
+++ b/crates/openhuman-rpc/src/server/cli.rs
@@ -71,13 +71,7 @@ pub(crate) fn flagged_builder(base: RuntimeBuilder, request: &ServeRequest) -> R
}
services
};
- super::shims::server_builder(
- base,
- services,
- request.host.as_deref(),
- request.port,
- None,
- )
+ super::shims::server_builder(base, services, request.host.as_deref(), request.port, None)
}
#[cfg(test)]
diff --git a/crates/openhuman-rpc/src/server/cli_tests.rs b/crates/openhuman-rpc/src/server/cli_tests.rs
index 4b76e9a457..55896273ac 100644
--- a/crates/openhuman-rpc/src/server/cli_tests.rs
+++ b/crates/openhuman-rpc/src/server/cli_tests.rs
@@ -55,7 +55,9 @@ fn explicit_flags_win_over_the_host_builder() {
let mut headless = request();
headless.headless_api = true;
assert_eq!(
- flagged_builder(host_builder(), &headless).summary().services,
+ flagged_builder(host_builder(), &headless)
+ .summary()
+ .services,
Some(ServiceSet::headless_api())
);
}
diff --git a/crates/openhuman-tinyhumans/src/runtime_tests.rs b/crates/openhuman-tinyhumans/src/runtime_tests.rs
index c47c7c0e2b..2b16a466e5 100644
--- a/crates/openhuman-tinyhumans/src/runtime_tests.rs
+++ b/crates/openhuman-tinyhumans/src/runtime_tests.rs
@@ -203,6 +203,9 @@ fn run_from_args_hands_the_connected_builder_to_the_cli_unchanged() {
assert!(summary.fixed_token);
assert_eq!(summary.listen_host.as_deref(), Some("0.0.0.0"));
assert_eq!(summary.listen_port, Some(7812));
- assert!(summary.has_backend_transport, "the server binds the transport");
+ assert!(
+ summary.has_backend_transport,
+ "the server binds the transport"
+ );
assert_eq!(summary.controller_extensions, vec![DomainGroup::Hosted]);
}