export function run()

in lib/testrunner.ts [28:52]


export function run(testsRoot: string, clb: (error, failures?: number) => void): void {

    // Enable source map support
    require('source-map-support').install();

    // Glob test files
    glob('**/**.test.js', { cwd: testsRoot }, (error, files) => {
        if (error) {
            return clb(error);
        }

        try {

            // Fill into Mocha
            files.forEach(f => mocha.addFile(paths.join(testsRoot, f)));

            // Run the tests
            mocha.run((failures) => {
                clb(null, failures);
            });
        } catch (error) {
            return clb(error);
        }
    });
}