app-server: allow remote_control runtime feature override (#20047)

This commit is contained in:
Ruslan Nigmatullin
2026-04-28 13:36:12 -07:00
committed by GitHub
parent e1ba87ccb2
commit 1de7a9bf69
3 changed files with 21 additions and 2 deletions

View File

@@ -306,6 +306,24 @@ async fn experimental_feature_enablement_set_only_updates_named_features() -> Re
Ok(())
}
#[tokio::test]
async fn experimental_feature_enablement_set_allows_remote_control() -> Result<()> {
let codex_home = TempDir::new()?;
let mut mcp = McpProcess::new(codex_home.path()).await?;
timeout(DEFAULT_TIMEOUT, mcp.initialize()).await??;
let remote_control_enabled = false;
let enablement = BTreeMap::from([("remote_control".to_string(), remote_control_enabled)]);
let actual = set_experimental_feature_enablement(&mut mcp, enablement.clone()).await?;
assert_eq!(
actual,
ExperimentalFeatureEnablementSetResponse { enablement }
);
Ok(())
}
#[tokio::test]
async fn experimental_feature_enablement_set_empty_map_is_no_op() -> Result<()> {
let codex_home = TempDir::new()?;
@@ -363,7 +381,7 @@ async fn experimental_feature_enablement_set_rejects_non_allowlisted_feature() -
);
assert!(
error.message.contains(
"apps, memories, plugins, tool_search, tool_suggest, tool_call_mcp_elicitation"
"apps, memories, plugins, remote_control, tool_search, tool_suggest, tool_call_mcp_elicitation"
),
"{}",
error.message