Skip to content

Commit 0ae12d0

Browse files
firelizzard18hyangah
authored andcommitted
src/goTest/resolve: fix Windows path handling
Fixes #1778 Change-Id: Ia9029ea6fbaad3701dbceeef463884104dadd2ea Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/350738 Reviewed-by: Hyang-Ah Hana Kim <[email protected]> Trust: Hyang-Ah Hana Kim <[email protected]> Trust: Robert Findley <[email protected]> Run-TryBot: Hyang-Ah Hana Kim <[email protected]> TryBot-Result: kokoro <[email protected]>
1 parent bff0d0a commit 0ae12d0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/goTest/resolve.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -304,11 +304,11 @@ export class GoTestResolver {
304304
let item: TestItem;
305305

306306
const nested = getGoConfig(uri).get('testExplorer.packageDisplayMode') === 'nested';
307-
const modDir = await getModFolderPath(uri, true);
307+
const modDir = Uri.file(await getModFolderPath(uri, true)); // TODO support non-file schemes
308308
const wsfolder = workspace.getWorkspaceFolder(uri);
309309
if (modDir) {
310310
// If the package is in a module, add it as a child of the module
311-
let parent = await this.getModule(uri.with({ path: modDir, query: '', fragment: '' }));
311+
let parent = await this.getModule(modDir);
312312
if (uri.path === parent.uri.path) {
313313
return parent;
314314
}

0 commit comments

Comments
 (0)