Skip to content

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

test: pass owned model name in session host tests

Steven Enamakel31b21c020de3
diff --git a/crates/openhuman-core/src/agent/session_host/imported_history_tests.rs b/crates/openhuman-core/src/agent/session_host/imported_history_tests.rs
index e50bd33115..888604361e 100644
--- a/crates/openhuman-core/src/agent/session_host/imported_history_tests.rs
+++ b/crates/openhuman-core/src/agent/session_host/imported_history_tests.rs
@@ -42,7 +42,7 @@ async fn run_imported_history_prefix_regression() {
let mut first = SessionHostBuilder::new()
.with_session_history_locator(Arc::clone(&locator))
.chat_model(first_chat_model)
- .model_name("test-model")
+ .model_name("test-model".to_owned())
.tools(vec![tool()])
.prompt_builder(crate::agent::prompts::SystemPromptBuilder::verbatim(
"You are the relay assistant. Preserve this exact system prefix.".to_owned(),
@@ -143,7 +143,7 @@ async fn run_imported_history_prefix_regression() {
let mut second = SessionHostBuilder::new()
.with_session_history_locator(locator)
.chat_model(second_chat_model)
- .model_name("test-model")
+ .model_name("test-model".to_owned())
.tools(vec![tool()])
.prompt_builder(crate::agent::prompts::SystemPromptBuilder::verbatim(
"This replacement prompt must not change an existing session.".to_owned(),
@@ -207,7 +207,7 @@ async fn legacy_history_is_loaded_only_for_an_unwritten_bound_session() {
let mut host = SessionHostBuilder::new()
.with_session_history_locator(Arc::clone(&locator))
.chat_model(chat_model)
- .model_name("test-model")
+ .model_name("test-model".to_owned())
.tools(vec![tool()])
.workspace_dir(root.path().join("workspace"))
.action_dir(root.path().to_path_buf())
@@ -308,7 +308,7 @@ async fn legacy_history_is_loaded_only_for_an_unwritten_bound_session() {
let mut resumed = SessionHostBuilder::new()
.with_session_history_locator(locator.clone())
.chat_model(second_chat_model)
- .model_name("test-model")
+ .model_name("test-model".to_owned())
.tools(vec![tool()])
.workspace_dir(second_root.path().join("workspace"))
.action_dir(second_root.path().to_path_buf())
diff --git a/crates/openhuman-core/src/agent/turn_host_tests.rs b/crates/openhuman-core/src/agent/turn_host_tests.rs
index 51770c78b7..585a7ebfcf 100644
--- a/crates/openhuman-core/src/agent/turn_host_tests.rs
+++ b/crates/openhuman-core/src/agent/turn_host_tests.rs
@@ -34,7 +34,7 @@ fn session_with_workspace(path: &str) -> OpenHumanSessionHost {
let chat_model: std::sync::Arc<dyn tinyinference_llm::model::ChatModel<()>> = model;
crate::agent::SessionHostBuilder::new()
.chat_model(chat_model)
- .model_name("test-model")
+ .model_name("test-model".to_owned())
.tools(Vec::new())
.workspace_dir(root.path().join("workspace"))
.action_dir(root.path().to_path_buf())