Skip to content

Commit 6abf068

Browse files
committed
Address another fedback with precedence testing
1 parent 2bf29c1 commit 6abf068

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

src/test/features/terminal/utils.unit.test.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,4 +528,20 @@ suite('Terminal Utils - shouldActivateInCurrentTerminal', () => {
528528
'workspaceValue false should take precedence over globalRemoteValue true',
529529
);
530530
});
531+
532+
test('should return false when globalValue is false even if workspaceValue is true (any explicit false wins)', () => {
533+
pythonConfig.inspect.withArgs('terminal.activateEnvInCurrentTerminal').returns({
534+
key: 'terminal.activateEnvInCurrentTerminal',
535+
defaultValue: false,
536+
globalValue: false,
537+
workspaceValue: true,
538+
workspaceFolderValue: undefined,
539+
});
540+
541+
assert.strictEqual(
542+
shouldActivateInCurrentTerminal(),
543+
false,
544+
'Any explicit false at any scope should return false, regardless of higher-precedence true values',
545+
);
546+
});
531547
});

0 commit comments

Comments
 (0)