0
0
mirror of https://github.com/nodejs/node.git synced 2024-12-01 16:10:02 +01:00
nodejs/test/parallel/test-next-tick-when-exiting.js

15 lines
295 B
JavaScript
Raw Normal View History

'use strict';
require('../common');
const assert = require('assert');
process.on('exit', () => {
assert.strictEqual(process._exiting, true, 'process._exiting was not set!');
process.nextTick(() => {
assert.fail('process is exiting, should not be called.');
});
});
process.exit();