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
test(profiles): expand credential parameter contract examples
Steven Enamakelf4f3bad8a059
diff --git a/crates/openhuman-core/src/core/all_profiles_controller_tests.rs b/crates/openhuman-core/src/core/all_profiles_controller_tests.rsindex 7fafcaa8b5..b9c2ff5c66 100644--- a/crates/openhuman-core/src/core/all_profiles_controller_tests.rs+++ b/crates/openhuman-core/src/core/all_profiles_controller_tests.rs@@ -6,7 +6,7 @@ fn raw_profiles_operator_registry_matches_its_independent_contract() {.iter().filter(|row| row.controller.schema.namespace == "profiles").collect();- let contracts = crate::profiles::schemas::tests::profile_parameter_contracts();+ let contracts = crate::profiles::schemas::profile_parameter_contracts();assert_eq!(entries.len(), 7, "complete raw Profiles inventory");assert_eq!(entriesdiff --git a/crates/openhuman-core/src/profiles/schemas.rs b/crates/openhuman-core/src/profiles/schemas.rsindex 28bd2f07fc..fce24de004 100644--- a/crates/openhuman-core/src/profiles/schemas.rs+++ b/crates/openhuman-core/src/profiles/schemas.rs@@ -271,4 +271,9 @@ fn bool_field(name: &'static str, comment: &'static str) -> FieldSchema {#[cfg(test)]#[path = "schemas_tests.rs"]-pub(crate) mod tests;+mod tests;++#[cfg(test)]+pub(crate) fn profile_parameter_contracts() -> Vec<crate::core::all::ControllerParamContract> {+ tests::profile_parameter_contracts()+}diff --git a/crates/openhuman-core/src/profiles/schemas_tests.rs b/crates/openhuman-core/src/profiles/schemas_tests.rsindex 82f172a704..260d43426d 100644--- a/crates/openhuman-core/src/profiles/schemas_tests.rs+++ b/crates/openhuman-core/src/profiles/schemas_tests.rs@@ -54,11 +54,25 @@ pub(crate) fn profile_parameter_contracts() -> Vec<crate::core::all::ControllerPmethod: "profiles.set_credential",required: &["profile_id", "kind", "token"],optional: &["expires_at"],- examples: vec![json!({- "profile_id":"profile-1",- "kind":"api_key",- "token":"fixture-only-token"- })],+ examples: vec![+ json!({+ "profile_id":"profile-1",+ "kind":"api_key",+ "token":"fixture-only-token"+ }),+ json!({+ "profile_id":"profile-1",+ "kind":"session",+ "token":"fixture-only-token",+ "expires_at":null+ }),+ json!({+ "profile_id":"profile-1",+ "kind":"session",+ "token":"fixture-only-token",+ "expires_at":"2030-01-02T03:04:05Z"+ }),+ ],},crate::core::all::ControllerParamContract {method: "profiles.clear_credential",