Add final message prefix to realtime handoff output (#15077)

- prefix realtime handoff output with the agent final message label for
both realtime v1 and v2
- update realtime websocket and core expectations to match
This commit is contained in:
Ahmed Ibrahim
2026-03-18 15:19:49 -07:00
committed by GitHub
parent 86982ca1f9
commit 7b37a0350f
3 changed files with 11 additions and 6 deletions

View File

@@ -1173,7 +1173,10 @@ mod tests {
let fourth_json: Value = serde_json::from_str(&fourth).expect("json");
assert_eq!(fourth_json["type"], "conversation.handoff.append");
assert_eq!(fourth_json["handoff_id"], "handoff_1");
assert_eq!(fourth_json["output_text"], "hello from codex");
assert_eq!(
fourth_json["output_text"],
"\"Agent Final Message\":\n\nhello from codex"
);
ws.send(Message::Text(
json!({
@@ -1504,7 +1507,7 @@ mod tests {
);
assert_eq!(
third_json["item"]["output"],
Value::String("delegated result".to_string())
Value::String("\"Agent Final Message\":\n\ndelegated result".to_string())
);
});