Skip to content

Commit 32822e0

Browse files
committed
remoteLaunchers: ensure test is normalizing paths
Explicitly call `fileToCommandArgumentForPythonExt` when computing a path with spaces and check results are as expected.
1 parent ef13e45 commit 32822e0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/test/unittest/adapter/remoteLaunchers.unit.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import * as path from 'path';
88
import { EXTENSION_ROOT_DIR } from '../../../extension/common/constants';
99
import '../../../extension/common/promiseUtils';
1010
import * as launchers from '../../../extension/debugger/adapter/remoteLaunchers';
11+
import { fileToCommandArgumentForPythonExt } from '../../../extension/common/stringUtils';
1112

1213
suite('External debugpy Debugger Launcher', () => {
1314
[
@@ -18,7 +19,7 @@ suite('External debugpy Debugger Launcher', () => {
1819
},
1920
{
2021
testName: 'When path to debugpy contains spaces',
21-
path: path.join('path', 'to', 'debugpy', 'with spaces'),
22+
path: fileToCommandArgumentForPythonExt(path.join('path', 'to', 'debugpy', 'with spaces')),
2223
expectedPath: '"path/to/debugpy/with spaces"',
2324
},
2425
].forEach((testParams) => {

0 commit comments

Comments
 (0)