Skip to content
This repository has been archived by the owner on Aug 15, 2019. It is now read-only.

Commit

Permalink
test_node: throw on unhandled promise rejections
Browse files Browse the repository at this point in the history
This makes `test-node` treat unhandled rejections as errors.
  • Loading branch information
ChALkeR committed Jul 10, 2018
1 parent 2fe1567 commit 949cdf1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/test_node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ import {MathBackendCPU} from './kernels/backend_cpu';
// tslint:disable-next-line:no-require-imports
const jasmine = require('jasmine');

process.on('unhandledRejection', e => { throw e; });

setTestEnvs(
[{name: 'node', factory: () => new MathBackendCPU(), features: {}}]);

Expand Down

0 comments on commit 949cdf1

Please sign in to comment.