Files
codex/codex-rs/ext/extension-api/tests/capabilities.rs
felixxia-oai 1fd392f6b2 Retire the unused Guardian extension prototype API (#45679)
## What changed

- Mark `guardian_ext` as a removed compatibility flag.
- Remove `InternalSessionSpawner`, `InternalSessionSpawnFuture`, `ApprovalReviewInput`, and `ApprovalReviewError` from the extension API, along with the spawner test.
- Remove `NodeReplReviewEvidence::review_inputs` and make the core re-exports of `NodeReplReviewEvidenceMode` crate-private.

GitOrigin-RevId: 1c532bc57264644cf521ef8077285a9b8ed67391
2026-09-15 11:39:20 +00:00

24 lines
747 B
Rust

use codex_extension_api::NoopResponseItemInjector;
use codex_extension_api::ResponseItemInjector;
use codex_protocol::models::ContentItem;
use codex_protocol::models::ResponseInputItem;
use pretty_assertions::assert_eq;
#[tokio::test]
async fn noop_response_item_injector_returns_original_items() {
let items = vec![ResponseInputItem::Message {
role: "user".to_string(),
content: vec![ContentItem::InputText {
text: "keep this input".to_string(),
}],
phase: None,
}];
let returned_items = NoopResponseItemInjector
.inject_response_items(items.clone())
.await
.expect_err("noop injector should reject same-turn injection");
assert_eq!(returned_items, items);
}