Skip to content

Commit 16df704

Browse files
authored
VSCode: respect VSCODE_TEST_VERSION environment variable in unit tests (#59)
1 parent d2fc6a8 commit 16df704

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

packages/databricks-vscode/src/test/runTest.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import path from "path";
22
import os from "os";
33

4-
import {runTests} from "@vscode/test-electron";
4+
import {downloadAndUnzipVSCode, runTests} from "@vscode/test-electron";
55

66
async function main() {
77
try {
@@ -13,8 +13,13 @@ async function main() {
1313
// Passed to --extensionTestsPath
1414
const extensionTestsPath = path.resolve(__dirname, "./suite");
1515

16+
const vscodeExecutablePath = await downloadAndUnzipVSCode(
17+
process.env.VSCODE_TEST_VERSION || "stable"
18+
);
19+
1620
// Download VS Code, unzip it and run the integration test
1721
await runTests({
22+
vscodeExecutablePath,
1823
extensionDevelopmentPath,
1924
extensionTestsPath,
2025
launchArgs: ["--user-data-dir", `${os.tmpdir()}`],

0 commit comments

Comments
 (0)