Skip to content

Commit b54859a

Browse files
committed
fix ci
1 parent 338792f commit b54859a

File tree

3 files changed

+30
-24
lines changed

3 files changed

+30
-24
lines changed

package-lock.json

Lines changed: 11 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/vscode-css-variables/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"description": "Autocomplete CSS Variable support CSS, SCSS, LESS, PostCSS, VueJS, ReactJS and more",
66
"publisher": "vunguyentuan",
77
"engines": {
8-
"vscode": "^1.63.0",
8+
"vscode": "^1.106.0",
99
"node": ">=20.0.0",
1010
"npm": ">=10.0.0"
1111
},

packages/vscode-css-variables/src/test/index.ts

Lines changed: 18 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -16,28 +16,24 @@ export async function run(): Promise<void> {
1616

1717
const testsRoot = __dirname;
1818

19-
try {
20-
const files = await glob('**.test.js', { cwd: testsRoot });
19+
const files = await glob('**.test.js', { cwd: testsRoot });
2120

22-
// Add files to the test suite
23-
files.forEach((f) => mocha.addFile(path.resolve(testsRoot, f)));
21+
// Add files to the test suite
22+
files.forEach((f) => mocha.addFile(path.resolve(testsRoot, f)));
2423

25-
// Run the mocha test
26-
return new Promise((resolve, reject) => {
27-
try {
28-
mocha.run((failures) => {
29-
if (failures > 0) {
30-
reject(new Error(`${failures} tests failed.`));
31-
} else {
32-
resolve();
33-
}
34-
});
35-
} catch (mochaError) {
36-
console.error(mochaError);
37-
reject(mochaError);
38-
}
39-
});
40-
} catch (err) {
41-
throw err;
42-
}
24+
// Run the mocha test
25+
return new Promise((resolve, reject) => {
26+
try {
27+
mocha.run((failures) => {
28+
if (failures > 0) {
29+
reject(new Error(`${failures} tests failed.`));
30+
} else {
31+
resolve();
32+
}
33+
});
34+
} catch (mochaError) {
35+
console.error(mochaError);
36+
reject(mochaError);
37+
}
38+
});
4339
}

0 commit comments

Comments
 (0)