fix(test): add TERM_PROGRAM_VERSION to OSC 8 detection tests

iTerm.app and vscode version-gated detection requires
TERM_PROGRAM_VERSION to be set. The beforeEach cleanup
deletes it, causing supportsOsc8Hyperlinks() to return
false and the OSC 8 envelope to not be emitted.
This commit is contained in:
DennisYu07 2026-07-08 10:18:23 +08:00
parent ac3c32e885
commit 32b9fc4a4a

View file

@ -2458,6 +2458,7 @@ describe('showFallbackMessage', () => {
configurable: true,
});
process.env['TERM_PROGRAM'] = 'iTerm.app';
process.env['TERM_PROGRAM_VERSION'] = '3.5.0';
showFallbackMessage('https://chat.qwen.ai/device?code=ABC123');
@ -2562,6 +2563,7 @@ describe('showFallbackMessage', () => {
configurable: true,
});
process.env['TERM_PROGRAM'] = 'vscode';
process.env['TERM_PROGRAM_VERSION'] = '1.85.0';
showFallbackMessage('https://chat.qwen.ai/device?code=ABC123');