diff --git a/tests/config.test.cjs b/tests/config.test.cjs index 0ec5659ec..3a981ba7b 100644 --- a/tests/config.test.cjs +++ b/tests/config.test.cjs @@ -83,7 +83,7 @@ describe('config-ensure-section command', () => { fs.mkdirSync(gsdDir, { recursive: true }); fs.writeFileSync(path.join(gsdDir, 'brave_api_key'), 'test-key', 'utf-8'); - const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir }); + const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir); @@ -100,7 +100,7 @@ describe('config-ensure-section command', () => { commit_docs: false, }), 'utf-8'); - const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir }); + const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir); @@ -119,7 +119,7 @@ describe('config-ensure-section command', () => { workflow: { research: false }, }), 'utf-8'); - const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir }); + const result = runGsdTools('config-ensure-section', tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir); @@ -340,7 +340,7 @@ describe('config-new-project command', () => { model_profile: 'balanced', workflow: { research: true, plan_check: true, verifier: true, nyquist_validation: true }, }); - const result = runGsdTools(['config-new-project', choices], tmpDir, { HOME: tmpDir }); + const result = runGsdTools(['config-new-project', choices], tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir); @@ -388,7 +388,7 @@ describe('config-new-project command', () => { model_profile: 'quality', workflow: { research: false, plan_check: false, verifier: true, nyquist_validation: false }, }); - const result = runGsdTools(['config-new-project', choices], tmpDir, { HOME: tmpDir }); + const result = runGsdTools(['config-new-project', choices], tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir); @@ -407,7 +407,7 @@ describe('config-new-project command', () => { }); test('works with empty choices — all defaults materialized', () => { - const result = runGsdTools(['config-new-project', '{}'], tmpDir, { HOME: tmpDir }); + const result = runGsdTools(['config-new-project', '{}'], tmpDir, { HOME: tmpDir, USERPROFILE: tmpDir }); assert.ok(result.success, `Command failed: ${result.error}`); const config = readConfig(tmpDir);