Skip to content

Commit

Permalink
test: Removes @vscode/test-electron (#114)
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
tylersmalley committed Jul 20, 2023
1 parent f40b6be commit c725c5b
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 345 deletions.
6 changes: 0 additions & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,6 @@ jobs:
key: yarn-cache
- name: Install dependencies
run: tool/yarn install --frozen-lockfile --prefer-offline
# - name: Integration Tests (Linux)
# run: xvfb-run -a tool/yarn test
# if: runner.os == 'Linux'
# - name: Integration Tests (macOS/Windows)
# run: tool/yarn test
# if: runner.os != 'Linux'
- name: Lint
run: tool/yarn lint
- name: Typescript
Expand Down
14 changes: 0 additions & 14 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,6 @@
},
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
"preLaunchTask": "${defaultBuildTask}"
},
{
"name": "Extension Tests",
"type": "extensionHost",
"request": "launch",
"args": [
"--extensionDevelopmentPath=${workspaceFolder}",
"--extensionTestsPath=${workspaceFolder}/out/test/suite/index"
],
"env": {
"NODE_ENV": "development"
},
"outFiles": ["${workspaceFolder}/out/**/*.js", "${workspaceFolder}/dist/**/*.js"],
"preLaunchTask": "tasks: watch-tests"
}
]
}
6 changes: 0 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -314,15 +314,11 @@
"package": "vsce package --allow-star-activation",
"precommit": "lint-staged",
"prepare": "husky install",
"pretest": "yarn run compile-tests && yarn run compile && yarn run lint",
"test": "tool/node ./out/test/run-test.js",
"vscode:prepublish": "(yarn run bundle-js & pid1=$!; yarn run bundle-go & pid2=$!; wait $pid1 || exit 1; wait $pid2 || exit 1)",
"watch-tests": "tsc -p . -w --outDir out",
"watch": "webpack serve"
},
"devDependencies": {
"@types/glob": "^8.1.0",
"@types/mocha": "^10.0.1",
"@types/node": "16.11.68",
"@types/react": "^18.2.15",
"@types/react-dom": "^18.2.7",
Expand All @@ -331,7 +327,6 @@
"@typescript-eslint/eslint-plugin": "^6.1.0",
"@typescript-eslint/parser": "^6.1.0",
"@vscode/codicons": "^0.0.33",
"@vscode/test-electron": "^2.3.3",
"@vscode/vsce": "^2.19.0",
"@vscode/webview-ui-toolkit": "^1.2.2",
"backport": "^8.9.8",
Expand All @@ -344,7 +339,6 @@
"glob": "^10.3.3",
"husky": "^8.0.3",
"lint-staged": "^13.2.3",
"mocha": "^10.2.0",
"node-fetch": "^3.3.1",
"postcss": "^8.4.26",
"postcss-loader": "^7.3.3",
Expand Down
23 changes: 0 additions & 23 deletions src/test/run-test.ts

This file was deleted.

15 changes: 0 additions & 15 deletions src/test/suite/extension.test.ts

This file was deleted.

34 changes: 0 additions & 34 deletions src/test/suite/index.ts

This file was deleted.

Loading

0 comments on commit c725c5b

Please sign in to comment.