mirror of
https://github.com/bearlanguageorg/bear.git
synced 2026-08-26 17:47:01 +00:00
VSCODE Exstention fix
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
// index.js — mocha bootstrap, executed inside the VS Code extension host.
|
||||
const path = require('path');
|
||||
const Mocha = require('mocha');
|
||||
|
||||
async function run() {
|
||||
const mocha = new Mocha({
|
||||
ui: 'tdd',
|
||||
timeout: 90000,
|
||||
reporter: 'spec',
|
||||
});
|
||||
mocha.addFile(path.join(__dirname, 'extension.test.js'));
|
||||
return new Promise((resolve, reject) => {
|
||||
mocha.run((failures) => {
|
||||
if (failures > 0) {
|
||||
reject(new Error(`${failures} test(s) failed`));
|
||||
} else {
|
||||
resolve();
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
module.exports = { run };
|
||||
Reference in New Issue
Block a user