Skip to content

Commit f44c569

Browse files
zmanianclaude
andcommitted
fix(agent): add missing source_channel args to thread_ops tests
Tests in thread_ops.rs failed to compile after Thread::with_id gained a third `source_channel` parameter and create_thread gained `Option<&str>`. Pass `None` / `Some("test")` as appropriate. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 617fec2 commit f44c569

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/agent/thread_ops.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2360,7 +2360,7 @@ mod tests {
23602360
// between lock acquisitions -- the TOCTOU window this fix addresses)
23612361
{
23622362
let mut sess = session.lock().await;
2363-
let mut thread = Thread::with_id(thread_id, session_id);
2363+
let mut thread = Thread::with_id(thread_id, session_id, None);
23642364
thread.start_turn("pending approval");
23652365
thread.state = ThreadState::AwaitingApproval;
23662366
sess.threads.insert(thread_id, thread);
@@ -2502,7 +2502,7 @@ mod tests {
25022502

25032503
let session_id = Uuid::new_v4();
25042504
let thread_id = Uuid::new_v4();
2505-
let mut thread = Thread::with_id(thread_id, session_id);
2505+
let mut thread = Thread::with_id(thread_id, session_id, None);
25062506

25072507
let correct_request_id = Uuid::new_v4();
25082508
let pending = PendingApproval {
@@ -2611,7 +2611,7 @@ mod tests {
26112611
use crate::agent::session::Session;
26122612

26132613
let mut session = Session::new("test-user");
2614-
let thread = session.create_thread();
2614+
let thread = session.create_thread(Some("test"));
26152615
let thread_id = thread.id;
26162616

26172617
// Set up a pending approval on the thread
@@ -2641,7 +2641,7 @@ mod tests {
26412641
use crate::agent::session::Session;
26422642

26432643
let mut session = Session::new("test-user");
2644-
let thread = session.create_thread();
2644+
let thread = session.create_thread(Some("test"));
26452645
let thread_id = thread.id;
26462646

26472647
// Set up a pending approval on the thread
@@ -2674,7 +2674,7 @@ mod tests {
26742674
use crate::agent::session::Session;
26752675

26762676
let mut session = Session::new("test-user");
2677-
let thread = session.create_thread();
2677+
let thread = session.create_thread(Some("test"));
26782678
let thread_id = thread.id;
26792679

26802680
// Set up a pending approval

0 commit comments

Comments
 (0)