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
chore: files changed crates/openhuman-core/src/mcp/module_client/cleanup_tests.rs,tests/saas_isolati
Steven Enamakel848d26101825
diff --git a/crates/openhuman-core/src/mcp/module_client/cleanup_tests.rs b/crates/openhuman-core/src/mcp/module_client/cleanup_tests.rsindex 120643bfa6..14b407f3dc 100644--- a/crates/openhuman-core/src/mcp/module_client/cleanup_tests.rs+++ b/crates/openhuman-core/src/mcp/module_client/cleanup_tests.rs@@ -416,3 +416,30 @@ async fn failed_cleanup_actions_retain_and_retry_cached_and_orphaned_paths() {assert!(!McpConfiguredClient::agent_close_pending(&orphan_dir));assert!(!orphan_dir.exists());}++#[test]+fn cleanup_callback_can_access_the_client_cache() {+ let workspace = tempfile::tempdir().expect("workspace");+ let mut config = Config::default();+ config.workspace_dir = workspace.path().to_path_buf();+ config.modules.enabled = true;+ McpConfiguredClient::install_test_port(&config, Box::new(FakePort::default()))+ .expect("install closed client");+ let cache_available = Arc::new(AtomicBool::new(false));+ let callback_flag = Arc::clone(&cache_available);+ McpConfiguredClient::schedule_agent_close_and_cleanup(+ workspace.path(),+ Arc::new(move || {+ callback_flag.store(+ CLIENTS.get().unwrap().try_lock().is_ok(),+ Ordering::SeqCst,+ );+ true+ }),+ );+ assert!(+ cache_available.load(Ordering::SeqCst),+ "cleanup callbacks must not hold the global client cache lock"+ );+ assert!(!McpConfiguredClient::agent_close_pending(workspace.path()));+}diff --git a/tests/saas_isolation/probes.rs b/tests/saas_isolation/probes.rsindex 81bcbcb33c..acacfd38fa 100644--- a/tests/saas_isolation/probes.rs+++ b/tests/saas_isolation/probes.rs@@ -45,7 +45,17 @@ fn saas_cli_does_not_expose_host_files_without_a_host_adapter() {assert_eq!(status, 200, "{body}");assert!(body.get("result").is_some(), "{body}");+ wait_until(+ "host-files inference request",+ &node,+ Duration::from_secs(60),+ || llm.recorded().iter().any(|request| request.is_inference()),+ );let requests = llm.recorded();+ assert!(+ requests.iter().any(|request| request.is_inference()),+ "the tool exposure assertion requires an inference request"+ );let offered: Vec<_> = requests.iter().filter(|request| request.is_inference())