fix: reconcile typed history with run exits
This commit is contained in:
@@ -66,7 +66,7 @@ async fn anthropic_thinking_round_trips_signature_into_history() {
|
||||
let client = MockLlmClient::new(events);
|
||||
let engine = Engine::new(client);
|
||||
let mut history: History = History::new();
|
||||
let _out = engine.run(&mut history, "question?").await.expect("run ok");
|
||||
let _out = engine.run(&mut history, "question?").await;
|
||||
|
||||
let entries = history.entries();
|
||||
// user / reasoning / assistant_message
|
||||
@@ -110,7 +110,7 @@ async fn openai_reasoning_round_trips_encrypted_and_summary() {
|
||||
let client = MockLlmClient::new(events);
|
||||
let engine = Engine::new(client);
|
||||
let mut history: History = History::new();
|
||||
let _out = engine.run(&mut history, "q").await.expect("run ok");
|
||||
let _out = engine.run(&mut history, "q").await;
|
||||
|
||||
let entries = history.entries();
|
||||
match &entries[1].item {
|
||||
@@ -156,7 +156,7 @@ async fn reasoning_precedes_text_in_assistant_burst() {
|
||||
let client = MockLlmClient::new(events);
|
||||
let engine = Engine::new(client);
|
||||
let mut history: History = History::new();
|
||||
let _out = engine.run(&mut history, "q").await.expect("run ok");
|
||||
let _out = engine.run(&mut history, "q").await;
|
||||
|
||||
let entries = history.entries();
|
||||
// user / reasoning(先頭) / assistant_message
|
||||
@@ -218,7 +218,7 @@ async fn injected_reasoning_survives_into_outgoing_request() {
|
||||
],
|
||||
);
|
||||
|
||||
let _ = engine.run(&mut history, "follow up").await.expect("run ok");
|
||||
let _ = engine.run(&mut history, "follow up").await;
|
||||
|
||||
let req = captured
|
||||
.lock()
|
||||
|
||||
Reference in New Issue
Block a user