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
fix(tests): add e2e test for memory tree sync raw coverage
Steven Enamakel46fcb5e2a106
diff --git a/tests/raw_coverage/memory_tree_sync_raw_coverage_e2e.rs b/tests/raw_coverage/memory_tree_sync_raw_coverage_e2e.rsindex 60c6a4def5..3067bb40c2 100644--- a/tests/raw_coverage/memory_tree_sync_raw_coverage_e2e.rs+++ b/tests/raw_coverage/memory_tree_sync_raw_coverage_e2e.rs@@ -414,85 +414,33 @@ async fn composio_providers_sync_state_and_bus_surfaces_cover_read_write_edges().await;}+// `default_composio_provider_hooks_cover_defaults_and_sync_preconditions`+// used to implement a `MinimalProvider: ComposioProvider` and exercise the+// trait's *default* method bodies: `identity_set`'s facet-count return,+// `fetch_tasks`'s "provider has no task-fetch surface" default error,+// `post_process_action_result`'s no-op default, `on_trigger`'s no-op+// default, and `sync`'s "memory client is not ready" precondition check.+//+// `ComposioProvider` itself — trait, default methods included — is one of+// the types tinymemory v1.13.4 deleted outright with the rest of the+// in-process Composio pipeline (see+// `crate::openhuman::integrations::composio::providers`'s module docs). It+// did not move to a replacement inside this crate: reaching a connected+// account now needs a credential this crate must not hold, so there is no+// trait left to implement a minimal provider against, default methods+// included. The nearest current behaviour — `run_sync_pass` refusing when no+// connectors module is loaded, and `task_sources::pipeline::fetch_tasks_unavailable`+// refusing task-board fetch for every toolkit — is already covered by+// `composio_get_user_profile_refuses_cleanly_without_a_loaded_module`-style+// tests elsewhere in this suite (see+// memory_sync_round23_raw_coverage_e2e.rs and+// json_rpc_e2e.rs::json_rpc_task_sources_fetch_pipeline_e2e), so this test+// keeps only the entity-canonicalisation coverage below, which has nothing+// to do with Composio and is untouched by the deletion. The trait-default+// coverage above is a genuine gap with no local equivalent — flagged in the+// migration report rather than papered over.#[tokio::test]-async fn default_composio_provider_hooks_cover_defaults_and_sync_preconditions() {- struct MinimalProvider;-- #[async_trait]- impl ComposioProvider for MinimalProvider {- fn toolkit_slug(&self) -> &'static str {- "round14"- }-- fn sync_interval_secs(&self) -> Option<u64> {- None- }-- fn curated_tools(&self) -> Option<&'static [CuratedTool]> {- Some(&[CuratedTool {- slug: "ROUND14_READ",- scope: ToolScope::Read,- }])- }-- async fn fetch_user_profile(- &self,- ctx: &ProviderContext,- ) -> Result<ProviderUserProfile, String> {- Ok(ProviderUserProfile {- toolkit: ctx.toolkit.clone(),- connection_id: ctx.connection_id.clone(),- display_name: Some("Round Fourteen".into()),- email: Some("[email protected]".into()),- username: Some("round14".into()),- avatar_url: None,- profile_url: None,- extras: json!({"source": "test"}),- })- }-- }-- let tmp = TempDir::new().expect("tempdir");- let cfg = Arc::new(config_in(&tmp));- let ctx = ProviderContext {- config: cfg,- toolkit: "round14".into(),- connection_id: Some("conn-round14".into()),- usage: Default::default(),- max_items: None,- sync_depth_days: None,- };- let provider = MinimalProvider;- assert_eq!(provider.sync_interval_secs(), None);- assert_eq!(provider.curated_tools().unwrap()[0].scope.as_str(), "read");- let facets_written = provider.identity_set(&provider.fetch_user_profile(&ctx).await.unwrap());- assert!(facets_written <= 4);-- let filter = TaskFetchFilter {- max: 0,- ..TaskFetchFilter::default()- };- assert_eq!(filter.effective_max(), 25);- let err = provider.fetch_tasks(&ctx, &filter).await.unwrap_err();- assert!(err.contains("provider has no task-fetch surface"));-- let mut data = json!({"ok": true});- provider.post_process_action_result("ROUND14_READ", None, &mut data);- assert_eq!(data, json!({"ok": true}));- provider- .on_trigger(&ctx, "ROUND14_TRIGGER", &json!({"ok": true}))- .await- .expect("default trigger no-op");-- let profile = provider.fetch_user_profile(&ctx).await.expect("profile");- assert_eq!(profile.email.as_deref(), Some("[email protected]"));- let sync_error = provider- .sync(&ctx, SyncReason::Manual)- .await- .expect_err("sync requires an initialized memory client");- assert!(sync_error.contains("memory client is not ready"));-+async fn memory_tree_entity_canonicalisation_covers_email_and_person_kinds() {let extracted = ExtractedEntities {entities: vec![openhuman_core::openhuman::memory::tree::score::extract::ExtractedEntity {