@@ -6,6 +6,7 @@ import test from "node:test";
66import type { AgentRequestOptions , AgentRunResult , AgentStatusSink } from "../dispatcher/AgentClient.js" ;
77import { normalizeCodexUsage } from "../dispatcher/CodexAppServerClient.js" ;
88import type { CodexAppServerClient } from "../dispatcher/CodexAppServerClient.js" ;
9+ import { PHONE_AGENT_SYSTEM_PROMPT } from "../dispatcher/promptPolicy.js" ;
910import type { ChatAttachment } from "../protocol/messages.js" ;
1011import { CODEX_WORKSPACE_NOT_FOUND_CODE } from "./chat/ChatErrors.js" ;
1112import { CodexChatClient } from "./CodexChatClient.js" ;
@@ -92,7 +93,7 @@ test("Codex new sessions create and reuse app-server threads", async () => {
9293 assert . equal ( created . key , "codex:019e0000-0000-7000-8000-000000000001" ) ;
9394 assert . equal ( created . sessionId , "019e0000-0000-7000-8000-000000000001" ) ;
9495 assert . equal ( fake . createdThreads [ 0 ] ?. model , "gpt-5.3-codex" ) ;
95- assert . match ( fake . createdThreads [ 0 ] ?. baseInstructions ?? "" , / a n d r o i d - c o n t r o l s k i l l / ) ;
96+ assert . equal ( fake . createdThreads [ 0 ] ?. baseInstructions , PHONE_AGENT_SYSTEM_PROMPT ) ;
9697
9798 await client . sendChat ( {
9899 sessionKey : created . key ! ,
@@ -218,7 +219,7 @@ test("Codex sends from implicit sessions create a durable thread first", async (
218219 await waitFor ( ( ) => fake . submitted . length === 1 ) ;
219220
220221 assert . equal ( fake . createdThreads . length , 1 ) ;
221- assert . match ( fake . createdThreads [ 0 ] ?. baseInstructions ?? "" , / a n d r o i d - c o n t r o l s k i l l / ) ;
222+ assert . equal ( fake . createdThreads [ 0 ] ?. baseInstructions , PHONE_AGENT_SYSTEM_PROMPT ) ;
222223 assert . equal ( fake . submitted [ 0 ] ?. options . threadId , "019e0000-0000-7000-8000-000000000001" ) ;
223224 assert . equal ( fake . submitted [ 0 ] ?. options . useSessionInstructions , true ) ;
224225 assert . equal ( fake . submitted [ 0 ] ?. text , "Hello" ) ;
0 commit comments