@@ -482,7 +482,7 @@ test('PR #39 frozen choice bytes consume once and keep fresh and resume transiti
482482 assertSnapshotMatchesScenario ( beforeOperation , scenario ) ;
483483 const oldJobRecord = scenario . records . find ( ( item ) => item . path . endsWith ( `${ scenario . operation . jobId } .json` ) ) ; const oldJobBytes = await readFile ( oldJobRecord . path ) ;
484484 const beforeBinding = JSON . parse ( await readFile ( scenario . records . find ( ( item ) => item . path . includes ( 'rescue-binding-session-' ) ) . path , 'utf8' ) ) . records [ 0 ] ;
485- const selected = await runChild ( process . execPath , [ cli , 'invoke-choice' , 'rescue' , choice ] , { cwd : ctx . workspace , env : { ...env , CODEX_THREAD_ID : scenario . agentId , FAKE_ZCODE_RECORD : record } } ) ;
485+ const selected = await runChild ( process . execPath , [ cli , 'invoke-choice' , 'rescue' , choice ] , { cwd : ctx . workspace , env : { ...env , CODEX_THREAD_ID : scenario . agentId , FAKE_ZCODE_RECORD : record , FAKE_ZCODE_WORKSPACE : target } } ) ;
486486 assert . equal ( selected . code , 0 , selected . stderr || selected . stdout ) ;
487487 await assert . rejects ( readFile ( pending . path ) , { code : 'ENOENT' } ) ; await assertPr39Immutable ( immutable ) ;
488488 assert . equal ( ( await store . listJobs ( ctx . workspace ) ) . length , 0 ) ; const jobs = await store . listJobs ( target ) ; assert . equal ( jobs . length , 2 ) ; assert . deepEqual ( await readFile ( oldJobRecord . path ) , oldJobBytes ) ;
@@ -523,7 +523,7 @@ test('PR #39 frozen stopped continuation consumes generation two and resumes its
523523 const beforeOperation = await documentedOperationSnapshot ( scenario . targetDirectory ) ;
524524 assertSnapshotMatchesScenario ( beforeOperation , scenario ) ;
525525 const oldJobRecord = scenario . records . find ( ( item ) => item . path . endsWith ( `${ scenario . operation . jobId } .json` ) ) ; const oldJobBytes = await readFile ( oldJobRecord . path ) ;
526- const continued = await runChild ( process . execPath , [ cli , 'invoke-prepared' , 'rescue' ] , { cwd : ctx . workspace , env : { ...env , CODEX_THREAD_ID : scenario . agentId , FAKE_ZCODE_RECORD : record } } ) ;
526+ const continued = await runChild ( process . execPath , [ cli , 'invoke-prepared' , 'rescue' ] , { cwd : ctx . workspace , env : { ...env , CODEX_THREAD_ID : scenario . agentId , FAKE_ZCODE_RECORD : record , FAKE_ZCODE_WORKSPACE : target } } ) ;
527527 assert . equal ( continued . code , 0 , continued . stderr || continued . stdout ) ; await assertPr39Immutable ( immutable ) ;
528528 const consumed = JSON . parse ( await readFile ( preparation . path , 'utf8' ) ) ;
529529 assert . equal ( consumed . generation , 2 ) ; assert . equal ( consumed . requiredExecutorAgentId , scenario . agentId ) ; assert . equal ( consumed . executorAgentId , scenario . agentId ) ; assert . notEqual ( consumed . consumedAt , null ) ;
0 commit comments