Skip to content

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

test: allow slower memory migration e2e

Steven Enamakel97db1c1c8b2f
diff --git a/tests/support/memory_engine_fixture.rs b/tests/support/memory_engine_fixture.rs
index 44729d83ff..6db575d370 100644
--- a/tests/support/memory_engine_fixture.rs
+++ b/tests/support/memory_engine_fixture.rs
@@ -607,7 +607,8 @@ impl Fixture {
/// Poll a migration job to a terminal state.
pub async fn wait_job(&self, job_id: &str) -> Value {
- for _ in 0..200 {
+ let deadline = tokio::time::Instant::now() + Duration::from_secs(60);
+ loop {
let v = self
.call(
"openhuman.memory_engine_migrate_status",
@@ -618,9 +619,12 @@ impl Fixture {
if status["state"] != "running" {
return status;
}
+ assert!(
+ tokio::time::Instant::now() < deadline,
+ "migration job {job_id} did not finish within 60 seconds"
+ );
tokio::time::sleep(Duration::from_millis(50)).await;
}
- panic!("migration job {job_id} did not finish");
}
pub async fn put_doc(&self, key: &str, content: &str) {