@@ -22,6 +22,7 @@ import {
2222} from "../plugins/runtime.js" ;
2323import { extractFirstTextBlock } from "../shared/chat-message-content.js" ;
2424import { createTestRegistry } from "../test-utils/channel-plugins.js" ;
25+ import { setTestEnvValue } from "../test-utils/env.js" ;
2526import { sleep } from "../utils.js" ;
2627import type { GatewayClient } from "./client.js" ;
2728import { connectTestGatewayClient } from "./gateway-cli-backend.live-helpers.js" ;
@@ -593,7 +594,7 @@ describeLive("gateway live (ACP bind)", () => {
593594 | undefined ;
594595
595596 clearRuntimeConfigSnapshot ( ) ;
596- process . env . OPENCLAW_STATE_DIR = tempStateDir ;
597+ setTestEnvValue ( " OPENCLAW_STATE_DIR" , tempStateDir ) ;
597598 process . env . OPENCLAW_SKIP_CHANNELS = "1" ;
598599 process . env . OPENCLAW_SKIP_GMAIL_WATCHER = "1" ;
599600 process . env . OPENCLAW_SKIP_CRON = "0" ;
@@ -682,7 +683,7 @@ describeLive("gateway live (ACP bind)", () => {
682683 } ,
683684 } ;
684685 await fs . writeFile ( tempConfigPath , `${ JSON . stringify ( nextCfg , null , 2 ) } \n` ) ;
685- process . env . OPENCLAW_CONFIG_PATH = tempConfigPath ;
686+ setTestEnvValue ( " OPENCLAW_CONFIG_PATH" , tempConfigPath ) ;
686687 logLiveStep ( `using parent live model ${ parentModel } ` ) ;
687688 clearConfigCache ( ) ;
688689 clearRuntimeConfigSnapshot ( ) ;
0 commit comments