2020-04-17 13:27:50 +00:00
|
|
|
/**
|
2024-01-03 10:11:33 +00:00
|
|
|
* @license
|
|
|
|
* Copyright 2020 Google Inc.
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
2020-04-17 13:27:50 +00:00
|
|
|
*/
|
|
|
|
|
2023-06-07 08:18:01 +00:00
|
|
|
let timeout = process.platform === 'win32' ? 20_000 : 10_000;
|
|
|
|
if (!!process.env.DEBUGGER_ATTACHED) {
|
|
|
|
timeout = 0;
|
|
|
|
}
|
2020-04-09 05:56:25 +00:00
|
|
|
module.exports = {
|
2022-06-15 10:05:25 +00:00
|
|
|
reporter: 'dot',
|
|
|
|
logLevel: 'debug',
|
|
|
|
require: ['./test/build/mocha-utils.js', 'source-map-support/register'],
|
|
|
|
exit: !!process.env.CI,
|
2023-03-24 08:35:45 +00:00
|
|
|
retries: process.env.CI ? 3 : 0,
|
2020-10-22 13:37:28 +00:00
|
|
|
parallel: !!process.env.PARALLEL,
|
2023-06-07 08:18:01 +00:00
|
|
|
timeout: timeout,
|
2020-10-22 13:37:28 +00:00
|
|
|
reporter: process.env.CI ? 'spec' : 'dot',
|
2023-09-29 09:32:53 +00:00
|
|
|
// This should make mocha crash on uncaught errors.
|
|
|
|
// See https://github.com/mochajs/mocha/blob/master/docs/index.md#--allow-uncaught.
|
|
|
|
allowUncaught: true,
|
|
|
|
// See https://github.com/mochajs/mocha/blob/master/docs/index.md#--async-only--a.
|
|
|
|
asyncOnly: true,
|
2020-04-09 05:56:25 +00:00
|
|
|
};
|