mirror of
https://github.com/nodejs/node.git
synced 2025-05-06 06:38:13 +00:00

In preparation for a lint rule enforcing function argument alignment, adjust function arguments to be aligned. PR-URL: https://github.com/nodejs/node/pull/6390 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Imran Iqbal <imran@imraniqbal.org> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
23 lines
574 B
JavaScript
23 lines
574 B
JavaScript
'use strict';
|
|
|
|
const common = require('../common');
|
|
const domain = require('domain');
|
|
const assert = require('assert');
|
|
|
|
const d = domain.create();
|
|
|
|
process.on('uncaughtException', common.mustCall(function onUncaught() {
|
|
assert.equal(process.domain, null,
|
|
'domains stack should be empty in uncaughtException handler');
|
|
}));
|
|
|
|
process.on('beforeExit', common.mustCall(function onBeforeExit() {
|
|
assert.equal(process.domain, null,
|
|
'domains stack should be empty in beforeExit handler');
|
|
}));
|
|
|
|
d.run(function() {
|
|
throw new Error('boom');
|
|
});
|
|
|