chore: add Prettier (#5825)

This commit is contained in:
Jack Franklin
2020-05-07 11:54:55 +01:00
committed by GitHub
parent ae576aff61
commit 4fdb1e3cab
109 changed files with 12166 additions and 7718 deletions

View File

@@ -1,5 +1,5 @@
const {describe, it} = require('mocha');
const {getCoverageResults} = require('./coverage-utils');
const { describe, it } = require('mocha');
const { getCoverageResults } = require('./coverage-utils');
const expect = require('expect');
describe('API coverage test', () => {
@@ -9,11 +9,12 @@ describe('API coverage test', () => {
const coverageMap = getCoverageResults();
const missingMethods = [];
for (const method of coverageMap.keys()) {
if (!coverageMap.get(method))
missingMethods.push(method);
if (!coverageMap.get(method)) missingMethods.push(method);
}
if (missingMethods.length) {
console.error('\nCoverage check failed: not all API methods called. See above output for list of missing methods.');
console.error(
'\nCoverage check failed: not all API methods called. See above output for list of missing methods.'
);
console.error(missingMethods.join('\n'));
}