fix(phase4): harden development acceptance adapters

This commit is contained in:
2026-08-24 16:57:25 +08:00
parent 964480a617
commit 37ec787bc1
13 changed files with 83 additions and 44 deletions
@@ -30,10 +30,10 @@ const overseasGateway = normalizeOrigin(option('--overseas-gateway') || process.
const password = acceptancePassword()
if (!password) throw new Error('缺少 CHONGCHONG_ADMIN_ACCEPTANCE_PASSWORD 或本机开发验收凭据文件')
const executable = process.platform === 'win32' ? 'pnpm.cmd' : 'pnpm'
const result = spawnSync(executable, ['exec', 'vitest', 'run', '--config', 'vitest.phase4-development.config.ts'], {
const result = spawnSync('pnpm', ['exec', 'vitest', 'run', '--config', 'vitest.phase4-development.config.ts'], {
cwd: process.cwd(),
stdio: 'inherit',
shell: process.platform === 'win32',
env: {
...process.env,
ADMIN_PHASE4_LIVE: '1',
@@ -45,4 +45,5 @@ const result = spawnSync(executable, ['exec', 'vitest', 'run', '--config', 'vite
VITE_OVERSEAS_API_BASE_URL: `${overseasGateway}/api`,
},
})
if (result.error) throw result.error
process.exit(result.status ?? 1)