node/test/fixtures/test-runner/custom_reporters/throwing-async.js

9 lines
177 B
JavaScript

'use strict';
module.exports = async function * customReporter() {
yield 'Going to throw an error\n';
setImmediate(() => {
throw new Error('Reporting error');
});
};