mirror of
https://github.com/openai/codex.git
synced 2026-09-05 15:18:41 +00:00
test(core): await apps inventory in startup-sensitive tests
This commit is contained in:
@@ -23,6 +23,7 @@ use core_test_support::responses::ev_response_created;
|
||||
use core_test_support::responses::mount_sse_sequence;
|
||||
use core_test_support::responses::sse;
|
||||
use core_test_support::responses::start_mock_server;
|
||||
use core_test_support::wait_for_mcp_server;
|
||||
use pretty_assertions::assert_eq;
|
||||
use serde_json::Value;
|
||||
use serde_json::json;
|
||||
@@ -155,6 +156,7 @@ async fn codex_apps_file_params_upload_local_paths_before_mcp_tool_call() -> Res
|
||||
trust_discovered_hooks(config);
|
||||
});
|
||||
let test = builder.build(&server).await?;
|
||||
wait_for_mcp_server(&test.codex, "codex_apps").await?;
|
||||
tokio::fs::write(test.cwd.path().join("report.txt"), b"hello world").await?;
|
||||
|
||||
test.submit_turn_with_approval_and_permission_profile(
|
||||
|
||||
@@ -258,6 +258,7 @@ async fn explicit_plugin_mentions_inject_plugin_guidance() -> Result<()> {
|
||||
build_apps_enabled_plugin_test_codex(&server, codex_home, apps_server.chatgpt_base_url)
|
||||
.await?;
|
||||
wait_for_mcp_server(&codex, "sample").await?;
|
||||
wait_for_mcp_server(&codex, "codex_apps").await?;
|
||||
|
||||
codex
|
||||
.submit(Op::UserInput {
|
||||
|
||||
@@ -253,6 +253,7 @@ async fn app_only_tools_are_not_visible_or_runnable_by_direct_model_calls() -> R
|
||||
|
||||
let mut builder = apps_enabled_builder(apps_server.chatgpt_base_url.clone());
|
||||
let test = builder.build(&server).await?;
|
||||
wait_for_mcp_server(&test.codex, "codex_apps").await?;
|
||||
test.submit_turn_with_approval_and_permission_profile(
|
||||
"Try to call the app-only calendar tool.",
|
||||
AskForApproval::Never,
|
||||
@@ -358,6 +359,7 @@ async fn search_tool_adds_discovery_instructions_to_tool_description() -> Result
|
||||
|
||||
let mut builder = configured_builder(apps_server.chatgpt_base_url.clone());
|
||||
let test = builder.build(&server).await?;
|
||||
wait_for_mcp_server(&test.codex, "codex_apps").await?;
|
||||
|
||||
test.submit_turn_with_approval_and_permission_profile(
|
||||
"list tools",
|
||||
|
||||
Reference in New Issue
Block a user