node/test/parallel/test-no-harmony-top-level-await.mjs
Michaël Zasso 05df701e70
test: remove common.disableCrashOnUnhandledRejection
Use the --unhandled-rejections=none CLI flag instead.

PR-URL: https://github.com/nodejs/node/pull/38210
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2021-04-14 16:42:10 +02:00

8 lines
194 B
JavaScript

// Flags: --no-harmony-top-level-await
import {
mustCall,
} from '../common/index.mjs';
process.on('unhandledRejection', mustCall());
Promise.reject(new Error('should not be fatal error'));