Skip to content

Commit 01a3f65

Browse files
committed
test: Removes @vscode/test-electron
We were not using this test infrastructure, and after #56 it should be better to accomplish these tests using something like playwright. @vscode/test-electron is really not ideal. It's heavy, and does not provide any tooling to test webviews, which we make use of. Signed-off-by: Tyler Smalley <tyler@tailscale.com>
1 parent de8514b commit 01a3f65

File tree

7 files changed

+28
-345
lines changed

7 files changed

+28
-345
lines changed

.github/workflows/test.yml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,8 @@ jobs:
2626
key: yarn-cache
2727
- name: Install dependencies
2828
run: tool/yarn install --frozen-lockfile --prefer-offline
29-
# - name: Integration Tests (Linux)
30-
# run: xvfb-run -a tool/yarn test
31-
# if: runner.os == 'Linux'
32-
# - name: Integration Tests (macOS/Windows)
33-
# run: tool/yarn test
34-
# if: runner.os != 'Linux'
29+
- name: Test
30+
run: tool/yarn test
3531
- name: Lint
3632
run: tool/yarn lint
3733
- name: Typescript

.vscode/launch.json

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,6 @@
1515
},
1616
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
1717
"preLaunchTask": "${defaultBuildTask}"
18-
},
19-
{
20-
"name": "Extension Tests",
21-
"type": "extensionHost",
22-
"request": "launch",
23-
"args": [
24-
"--extensionDevelopmentPath=${workspaceFolder}",
25-
"--extensionTestsPath=${workspaceFolder}/out/test/suite/index"
26-
],
27-
"env": {
28-
"NODE_ENV": "development"
29-
},
30-
"outFiles": ["${workspaceFolder}/out/**/*.js", "${workspaceFolder}/dist/**/*.js"],
31-
"preLaunchTask": "tasks: watch-tests"
3218
}
3319
]
3420
}

package.json

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -278,15 +278,11 @@
278278
"package": "vsce package --allow-star-activation",
279279
"precommit": "lint-staged",
280280
"prepare": "husky install",
281-
"pretest": "yarn run compile-tests && yarn run compile && yarn run lint",
282-
"test": "tool/node ./out/test/run-test.js",
283281
"vscode:prepublish": "(yarn run bundle-js & pid1=$!; yarn run bundle-go & pid2=$!; wait $pid1 || exit 1; wait $pid2 || exit 1)",
284-
"watch-tests": "tsc -p . -w --outDir out",
285282
"watch": "webpack serve"
286283
},
287284
"devDependencies": {
288285
"@types/glob": "^8.1.0",
289-
"@types/mocha": "^10.0.1",
290286
"@types/node": "16.11.68",
291287
"@types/react": "^18.2.15",
292288
"@types/react-dom": "^18.2.7",
@@ -295,7 +291,6 @@
295291
"@typescript-eslint/eslint-plugin": "^6.1.0",
296292
"@typescript-eslint/parser": "^6.1.0",
297293
"@vscode/codicons": "^0.0.33",
298-
"@vscode/test-electron": "^2.3.3",
299294
"@vscode/vsce": "^2.19.0",
300295
"@vscode/webview-ui-toolkit": "^1.2.2",
301296
"backport": "^8.9.8",
@@ -308,7 +303,6 @@
308303
"glob": "^10.3.3",
309304
"husky": "^8.0.3",
310305
"lint-staged": "^13.2.3",
311-
"mocha": "^10.2.0",
312306
"node-fetch": "^3.3.1",
313307
"postcss": "^8.4.26",
314308
"postcss-loader": "^7.3.3",

src/test/run-test.ts

Lines changed: 0 additions & 23 deletions
This file was deleted.

src/test/suite/extension.test.ts

Lines changed: 0 additions & 15 deletions
This file was deleted.

src/test/suite/index.ts

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)