diff --git a/helloworld-test-sample/src/test/suite/index.ts b/helloworld-test-sample/src/test/suite/index.ts index 10bb1fb8..236a4e7f 100644 --- a/helloworld-test-sample/src/test/suite/index.ts +++ b/helloworld-test-sample/src/test/suite/index.ts @@ -5,8 +5,9 @@ import * as glob from 'glob'; export function run(testsRoot: string, cb: (error: any, failures?: number) => void): void { // Create the mocha test const mocha = new Mocha({ - ui: 'tdd', + ui: 'tdd' }); + // Use any mocha API mocha.useColors(true); glob('**/**.test.js', { cwd: testsRoot }, (err, files) => { @@ -20,7 +21,6 @@ export function run(testsRoot: string, cb: (error: any, failures?: number) => vo try { // Run the mocha test mocha.run(failures => cb(null, failures)); - } catch (err) { cb(err); }