File tree Expand file tree Collapse file tree 9 files changed +22
-81
lines changed
Expand file tree Collapse file tree 9 files changed +22
-81
lines changed Original file line number Diff line number Diff line change 2424 yarn run compile-web
2525 - name : Test
2626 run : |
27+ yarn run compile-tests
2728 xvfb-run -a yarn run test
2829 xvfb-run -a yarn run test-web
2930 - name : Publish
Original file line number Diff line number Diff line change 11test.temp
22.DS_Store
33
4- / out
4+ out
55out-view
66dist
77node_modules
Original file line number Diff line number Diff line change 1- packages
1+ .vscode
2+ out /
3+ src /
4+ tsconfig.json
5+ webpack.config.js
6+ esbuild.js
27yarn.lock
3-
4- .vscode /**
58.vscode-test /**
6- out /test /**
79views /**
810test.temp /**
9-
10- src /**
1111.gitignore
1212.yarnrc
1313vsc-extension-quickstart.md
14- ** /tsconfig.json
1514** /.eslintrc.json
1615** /* .map
1716** /* .ts
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ async function main() {
1212 sourcemap : ! production ,
1313 sourcesContent : false ,
1414 platform : "node" ,
15- outfile : "out /extension.js" ,
15+ outfile : "dist /extension.js" ,
1616 external : [ "vscode" , "jsonc-parser" ] ,
1717 logLevel : "silent" ,
1818 plugins : [
Original file line number Diff line number Diff line change 3737 "editor-view:watch" : " webpack --config ./views/code-snippets-editor/webpack.config.js --watch" ,
3838 "eslint-fix" : " eslint --fix ." ,
3939 "prettier-fix" : " prettier --write ." ,
40- "test" : " node esbuild-test.js && node ./test/runTest.js" ,
40+ "compile-tests" : " tsc -p . --outDir out" ,
41+ "test" : " node ./out/test/runTest.js" ,
4142 "test-web" : " node ./test/runTestWeb.js" ,
4243 "watch" : " concurrently \" yarn run editor-view:watch\" \" node esbuild.js --watch\" " ,
4344 "watch-web" : " webpack --watch" ,
Original file line number Diff line number Diff line change 1- const path = require ( "path" ) ;
2- const { runTests } = require ( "@vscode/test-electron" ) ;
1+ import * as path from "path" ;
2+
3+ import { runTests } from "@vscode/test-electron" ;
34
45async function main ( ) {
56 try {
67 // The folder containing the Extension Manifest package.json
78 // Passed to `--extensionDevelopmentPath`
8- const extensionDevelopmentPath = path . resolve ( __dirname , "../" ) ;
9+ const extensionDevelopmentPath = path . resolve ( __dirname , "../../ " ) ;
910
1011 // The path to test runner
1112 // Passed to --extensionTestsPath
12- const extensionTestsPath = path . resolve (
13- __dirname ,
14- "../out/test/suite/index" ,
15- ) ;
13+ const extensionTestsPath = path . resolve ( __dirname , "./suite/index" ) ;
1614
1715 // Download VS Code, unzip it and run the integration test
1816 await runTests ( {
Original file line number Diff line number Diff line change 1- const path = require ( "path" ) ;
2- const { runTests } = require ( "@vscode/test-web" ) ;
1+ import * as path from "path" ;
2+ import { runTests } from "@vscode/test-web" ;
33
44async function main ( ) {
55 try {
66 // The folder containing the Extension Manifest package.json
77 // Passed to `--extensionDevelopmentPath`
8- const extensionDevelopmentPath = path . resolve ( __dirname , "../" ) ;
8+ const extensionDevelopmentPath = path . resolve ( __dirname , "../../ " ) ;
99
1010 // The path to test runner
1111 // Passed to --extensionTestsPath
1212 const extensionTestsPath = path . resolve (
1313 __dirname ,
14- "../dist/web/test/suite/index" ,
14+ "../../ dist/web/test/suite/index" ,
1515 ) ;
1616
1717 // Download VS Code, unzip it and run the integration test
Original file line number Diff line number Diff line change 11import * as path from "path" ;
2+ import * as Mocha from "mocha" ;
23import * as glob from "glob" ;
34
4- // eslint-disable-next-line @typescript-eslint/no-require-imports
5- const Mocha = require ( "mocha" ) ;
6-
75export function run ( ) : Promise < void > {
86 // Create the mocha test
97 const mocha = new Mocha ( {
@@ -25,7 +23,7 @@ export function run(): Promise<void> {
2523
2624 try {
2725 // Run the mocha test
28- mocha . run ( ( failures : any ) => {
26+ mocha . run ( ( failures ) => {
2927 if ( failures > 0 ) {
3028 e ( new Error ( `${ failures } tests failed.` ) ) ;
3129 } else {
You can’t perform that action at this time.
0 commit comments