Skip to content

armgit / codex

Public Imported from GitHub
0

Lightweight coding agent that runs in your terminal

Rust

Fix extension turn item emitter test event ordering (#24936)

Michael Bolin2264fdd4a2bb
diff --git a/codex-rs/core/src/tools/handlers/extension_tools.rs b/codex-rs/core/src/tools/handlers/extension_tools.rs
index e9b16e97d5..d04a6c520e 100644
--- a/codex-rs/core/src/tools/handlers/extension_tools.rs
+++ b/codex-rs/core/src/tools/handlers/extension_tools.rs
@@ -271,6 +271,11 @@ mod tests {
session
.record_conversation_items(&turn, std::slice::from_ref(&history_item))
.await;
+ let raw_history_event = rx.recv().await.expect("history raw response item event");
+ let EventMsg::RawResponseItem(raw_history_item) = raw_history_event.msg else {
+ panic!("expected raw response item event");
+ };
+ assert_eq!(raw_history_item.item, history_item);
let invocation = ToolInvocation {
session,
turn,